1
0
Fork 0
mirror of https://github.com/codex-team/codex.docs.git synced 2025-07-28 01:29:42 +02:00

Some design updates (#70)

* Auth page styles improved

* styles updated

* upd bundles
This commit is contained in:
Peter Savchenko 2019-03-13 12:25:43 +03:00 committed by GitHub
parent 7c7c0d62d9
commit c7219f8943
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
20 changed files with 288 additions and 48 deletions

View file

@ -1,5 +1,5 @@
const urlify = require('../utils/urlify');
const { pages: pagesDb } = require('../utils/database/index');
const translateString = require('../utils/translation');
/**
* @typedef {Object} PageData
@ -116,14 +116,7 @@ class Page {
* @return {string}
*/
transformTitleToUri() {
return translateString(this.title
.replace(/ /g, ' ')
.replace(/[^a-zA-Z0-9А-Яа-яЁё ]/g, ' ')
.replace(/ +/g, ' ')
.trim()
.toLowerCase()
.split(' ')
.join('-'));
return urlify(this.title);
}
/**