« get me outta code hell

hsmusic-wiki - HSMusic - static wiki software cataloguing collaborative creation
about summary refs log tree commit diff
path: root/src/data/things/language.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/data/things/language.js')
-rw-r--r--src/data/things/language.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/data/things/language.js b/src/data/things/language.js
index 0638afa2..c98495dc 100644
--- a/src/data/things/language.js
+++ b/src/data/things/language.js
@@ -1,6 +1,10 @@
 import {isLanguageCode} from '#validators';
 
-import Thing from './thing.js';
+import Thing, {
+  externalFunction,
+  flag,
+  simpleString,
+} from './thing.js';
 
 export class Language extends Thing {
   static [Thing.getPropertyDescriptors] = () => ({
@@ -16,7 +20,7 @@ export class Language extends Thing {
 
     // Human-readable name. This should be the language's own native name, not
     // localized to any other language.
-    name: Thing.common.simpleString(),
+    name: simpleString(),
 
     // Language code specific to JavaScript's Internationalization (Intl) API.
     // Usually this will be the same as the language's general code, but it
@@ -38,7 +42,7 @@ export class Language extends Thing {
     // with languages that are currently in development and not ready for
     // formal release, or which are just kept hidden as "experimental zones"
     // for wiki development or content testing.
-    hidden: Thing.common.flag(false),
+    hidden: flag(false),
 
     // Mapping of translation keys to values (strings). Generally, don't
     // access this object directly - use methods instead.
@@ -66,7 +70,7 @@ export class Language extends Thing {
 
     // Update only
 
-    escapeHTML: Thing.common.externalFunction(),
+    escapeHTML: externalFunction(),
 
     // Expose only