alchemy-chimera 0.5.4 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (128) hide show
  1. package/CHANGELOG.md +39 -4
  2. package/assets/scripts/chimera/chimera.js +13 -288
  3. package/assets/stylesheets/chimera/chimera.scss +451 -0
  4. package/bootstrap.js +6 -302
  5. package/config/routes.js +53 -5
  6. package/controller/00-chimera_controller.js +16 -0
  7. package/controller/chimera_editor_controller.js +159 -614
  8. package/controller/chimera_static_controller.js +102 -9
  9. package/lib/chimera_config.js +138 -163
  10. package/model/model.js +1 -1
  11. package/package.json +8 -12
  12. package/view/chimera/dashboard.hwk +8 -0
  13. package/view/chimera/editor/index.hwk +20 -0
  14. package/view/chimera/sidebar.hwk +4 -0
  15. package/view/chimera/widgets.hwk +8 -0
  16. package/view/layouts/chimera_base.hwk +15 -0
  17. package/view/layouts/chimera_basics.hwk +15 -0
  18. package/view/layouts/chimera_body.hwk +24 -0
  19. package/assets/scripts/chimera/assoc_field.js +0 -311
  20. package/assets/scripts/chimera/boolean_field.js +0 -53
  21. package/assets/scripts/chimera/chimera_field.js +0 -622
  22. package/assets/scripts/chimera/chimera_field_wrapper.js +0 -558
  23. package/assets/scripts/chimera/date_field.js +0 -170
  24. package/assets/scripts/chimera/geopoint_field.js +0 -147
  25. package/assets/scripts/chimera/medium-button.js +0 -6
  26. package/assets/scripts/chimera/object_field.js +0 -51
  27. package/assets/scripts/chimera/page-editor.js +0 -3
  28. package/assets/scripts/chimera/password_field.js +0 -73
  29. package/assets/scripts/chimera/schema_field.js +0 -300
  30. package/assets/scripts/chimera/text_field.js +0 -119
  31. package/assets/scripts/rome/rome.js +0 -4978
  32. package/assets/scripts/vex/vex.dialog.js +0 -151
  33. package/assets/scripts/vex/vex.js +0 -193
  34. package/assets/stylesheets/chimera/chimera.less +0 -1075
  35. package/assets/stylesheets/chimera_old/chimera.less +0 -351
  36. package/assets/stylesheets/chimera_old/core.less +0 -315
  37. package/assets/stylesheets/chimera_old/font.less +0 -38
  38. package/assets/stylesheets/chimera_old/mixins.less +0 -35
  39. package/assets/stylesheets/chimera_old/page-editor.less +0 -23
  40. package/assets/stylesheets/rome/rome.less +0 -130
  41. package/assets/stylesheets/vex/vex-theme-bottom-right-corner.less +0 -613
  42. package/assets/stylesheets/vex/vex.default.less +0 -501
  43. package/assets/stylesheets/vex/vex.flat.less +0 -443
  44. package/assets/stylesheets/vex/vex.less +0 -320
  45. package/controller/chimera_page_controller.js +0 -14
  46. package/controller/chimera_settings_controller.js +0 -129
  47. package/controller/tasks_chimera_controller.js +0 -106
  48. package/helper/chimera_helper.js +0 -202
  49. package/lib/chimera_action_fields.js +0 -292
  50. package/lib/chimera_field/belongsto_chimera_field.js +0 -160
  51. package/lib/chimera_field/boolean_chimera_field.js +0 -19
  52. package/lib/chimera_field/date_chimera_field.js +0 -20
  53. package/lib/chimera_field/datetime_chimera_field.js +0 -20
  54. package/lib/chimera_field/enum_chimera_field.js +0 -131
  55. package/lib/chimera_field/geopoint_chimera_field.js +0 -20
  56. package/lib/chimera_field/habtm_chimera_field.js +0 -55
  57. package/lib/chimera_field/hasoneparent_chimera_field.js +0 -18
  58. package/lib/chimera_field/html_chimera_field.js +0 -20
  59. package/lib/chimera_field/object_chimera_field.js +0 -18
  60. package/lib/chimera_field/password_chimera_field.js +0 -18
  61. package/lib/chimera_field/schema_chimera_field.js +0 -149
  62. package/lib/chimera_field/text_chimera_field.js +0 -20
  63. package/lib/chimera_field/time_chimera_field.js +0 -18
  64. package/lib/chimera_field.js +0 -208
  65. package/model/setting_model.js +0 -51
  66. package/public/chimera/codedor.svg +0 -28
  67. package/view/chimera/dashboard.ejs +0 -5
  68. package/view/chimera/editor/add.ejs +0 -32
  69. package/view/chimera/editor/edit.ejs +0 -33
  70. package/view/chimera/editor/index.ejs +0 -87
  71. package/view/chimera/editor/remove.ejs +0 -23
  72. package/view/chimera/editor/view.ejs +0 -54
  73. package/view/chimera/elements/editor_actions.ejs +0 -4
  74. package/view/chimera/elements/empty +0 -0
  75. package/view/chimera/field_wrappers/_entries.ejs +0 -91
  76. package/view/chimera/field_wrappers/_wrapper.ejs +0 -82
  77. package/view/chimera/field_wrappers/date_edit.ejs +0 -23
  78. package/view/chimera/field_wrappers/date_list.ejs +0 -3
  79. package/view/chimera/field_wrappers/date_view.ejs +0 -16
  80. package/view/chimera/field_wrappers/default_edit.ejs +0 -22
  81. package/view/chimera/field_wrappers/default_list.ejs +0 -3
  82. package/view/chimera/field_wrappers/default_peek.ejs +0 -3
  83. package/view/chimera/field_wrappers/default_view.ejs +0 -14
  84. package/view/chimera/field_wrappers/geopoint_edit.ejs +0 -25
  85. package/view/chimera/field_wrappers/geopoint_list.ejs +0 -5
  86. package/view/chimera/field_wrappers/geopoint_view.ejs +0 -18
  87. package/view/chimera/field_wrappers/schema_edit.ejs +0 -19
  88. package/view/chimera/field_wrappers/text_edit.ejs +0 -22
  89. package/view/chimera/field_wrappers/text_list.ejs +0 -1
  90. package/view/chimera/fields/belongsto_edit.ejs +0 -4
  91. package/view/chimera/fields/belongsto_list.ejs +0 -1
  92. package/view/chimera/fields/belongsto_peek.ejs +0 -1
  93. package/view/chimera/fields/boolean_edit.ejs +0 -17
  94. package/view/chimera/fields/boolean_list.ejs +0 -3
  95. package/view/chimera/fields/boolean_view.ejs +0 -3
  96. package/view/chimera/fields/date_edit.ejs +0 -14
  97. package/view/chimera/fields/date_list.ejs +0 -9
  98. package/view/chimera/fields/date_peek.ejs +0 -9
  99. package/view/chimera/fields/date_view.ejs +0 -9
  100. package/view/chimera/fields/datetime_edit.ejs +0 -24
  101. package/view/chimera/fields/datetime_list.ejs +0 -9
  102. package/view/chimera/fields/datetime_view.ejs +0 -10
  103. package/view/chimera/fields/default_edit.ejs +0 -10
  104. package/view/chimera/fields/default_list.ejs +0 -15
  105. package/view/chimera/fields/default_view.ejs +0 -1
  106. package/view/chimera/fields/enum_edit.ejs +0 -10
  107. package/view/chimera/fields/geopoint_edit.ejs +0 -10
  108. package/view/chimera/fields/geopoint_list.ejs +0 -9
  109. package/view/chimera/fields/geopoint_view.ejs +0 -9
  110. package/view/chimera/fields/habtm_edit.ejs +0 -5
  111. package/view/chimera/fields/hasoneparent_edit.ejs +0 -6
  112. package/view/chimera/fields/hasoneparent_list.ejs +0 -1
  113. package/view/chimera/fields/object_edit.ejs +0 -8
  114. package/view/chimera/fields/password_edit.ejs +0 -12
  115. package/view/chimera/fields/schema_edit.ejs +0 -14
  116. package/view/chimera/fields/text_edit.ejs +0 -5
  117. package/view/chimera/fields/text_list.ejs +0 -9
  118. package/view/chimera/fields/text_view.ejs +0 -3
  119. package/view/chimera/fields/time_edit.ejs +0 -15
  120. package/view/chimera/fields/time_list.ejs +0 -9
  121. package/view/chimera/fields/time_view.ejs +0 -9
  122. package/view/chimera/page/edit.ejs +0 -18
  123. package/view/chimera/page_editor.ejs +0 -5
  124. package/view/chimera/sidebar.ejs +0 -40
  125. package/view/chimera/tasks/index.ejs +0 -114
  126. package/view/layouts/chimera.ejs +0 -12
  127. package/view/layouts/chimera_base.ejs +0 -11
  128. package/view/layouts/chimera_body.ejs +0 -43
@@ -1,24 +1,117 @@
1
1
  /**
2
2
  * The Chimera Static Controller class
3
3
  *
4
- * @author Jelle De Loecker <jelle@kipdola.be>
5
- * @since 0.2.0
6
- * @version 0.3.0
4
+ * @author Jelle De Loecker <jelle@elevenways.be>
5
+ * @since 0.2.0
6
+ * @version 1.0.0
7
7
  */
8
- var ChimeraStatic = Function.inherits('Alchemy.Controller.Chimera', function Static(conduit) {
9
- Static.super.call(this, conduit);
10
- });
8
+ const ChimeraStatic = Function.inherits('Alchemy.Controller.Chimera', 'Static');
11
9
 
12
10
  /**
13
11
  * The dashboard action
14
12
  *
15
- * @param {Conduit} conduit
13
+ * @author Jelle De Loecker <jelle@elevenways.be>
14
+ * @since 0.1.0
15
+ * @version 1.0.0
16
+ *
17
+ * @param {Conduit} conduit
16
18
  */
17
19
  ChimeraStatic.setAction(function dashboard(conduit) {
18
20
  this.set('pagetitle', 'Dashboard');
19
21
  this.render('chimera/dashboard');
20
22
  });
21
23
 
22
- ChimeraStatic.setAction(function pageEditor(conduit) {
23
- this.render('chimera/page_editor');
24
+ /**
25
+ * The sidebar action
26
+ *
27
+ * @author Jelle De Loecker <jelle@elevenways.be>
28
+ * @since 1.0.0
29
+ * @version 1.0.1
30
+ *
31
+ * @param {Conduit} conduit
32
+ */
33
+ ChimeraStatic.setAction(function sidebar(conduit) {
34
+
35
+ let widgets = [],
36
+ config;
37
+
38
+ if (Array.isArray(alchemy.plugins.chimera.sidebar_menu)) {
39
+
40
+ for (let entry of alchemy.plugins.chimera.sidebar_menu) {
41
+
42
+ if (!entry.model && !entry.href) {
43
+ continue;
44
+ }
45
+
46
+ let model,
47
+ title = entry.title;
48
+
49
+ if (entry.model) {
50
+ model = Model.get(entry.model);
51
+ }
52
+
53
+ if (!title) {
54
+ if (model) {
55
+ title = model.constructor.title;
56
+ }
57
+
58
+ if (!title && entry.href) {
59
+ title = entry.href;
60
+ }
61
+ }
62
+
63
+ if (entry.href) {
64
+ widgets.push({
65
+ type : 'link',
66
+ config : {
67
+ href : entry.href,
68
+ content: title
69
+ }
70
+ });
71
+ } else {
72
+
73
+ widgets.push({
74
+ type : 'link',
75
+ config : {
76
+ route : 'Chimera.Editor#index',
77
+ parameters: [
78
+ {name: 'model', value: model.constructor.type_name},
79
+ ],
80
+ content: title
81
+ }
82
+ });
83
+ }
84
+ }
85
+
86
+ } else {
87
+
88
+ let models = Model.getAllChildren();
89
+ models.sortByPath(1, 'model_name');
90
+
91
+ for (let model of models) {
92
+ widgets.push({
93
+ type : 'link',
94
+ config : {
95
+ route : 'Chimera.Editor#index',
96
+ parameters: [
97
+ {name: 'model', value: model.type_name},
98
+ ],
99
+ content: model.title
100
+ }
101
+ });
102
+ }
103
+ }
104
+
105
+ config = [
106
+ {
107
+ "type": "navigation",
108
+ "config": {
109
+ "widgets": widgets
110
+ }
111
+ }
112
+ ];
113
+
114
+ this.set('navigation_widgets', config);
115
+
116
+ this.renderSegment('chimera/sidebar');
24
117
  });
@@ -5,218 +5,193 @@
5
5
  *
6
6
  * @constructor
7
7
  *
8
- * @author Jelle De Loecker <jelle@develry.be>
8
+ * @author Jelle De Loecker <jelle@elevenways.be>
9
9
  * @since 0.2.0
10
- * @version 0.3.0
10
+ * @version 1.0.0
11
11
  *
12
12
  * @param {Model} ModelClass
13
13
  */
14
- var ChimeraConfig = Function.inherits('Alchemy.Base', function ChimeraConfig(ModelClass) {
14
+ const Config = Function.inherits('Alchemy.Base', 'Alchemy.Chimera', function Config(ModelClass) {
15
15
 
16
16
  // The modal class constructor
17
17
  this.ModelClass = ModelClass;
18
18
 
19
- // The different action groups
20
- this.actionGroups = {};
19
+ // The different default field sets
20
+ this.field_sets = {};
21
21
  });
22
22
 
23
23
  /**
24
- * Show filter fields on index pages
24
+ * Get the fieldset for a specific action
25
25
  *
26
- * @author Jelle De Loecker <jelle@develry.be>
27
- * @since 0.2.1
28
- * @version 0.2.1
26
+ * @deprecated
29
27
  *
30
- * @type {Boolean}
31
- */
32
- ChimeraConfig.setProperty('show_index_filters', true);
33
-
34
- /**
35
- * See if this model's blueprint contains translation fields
36
- *
37
- * @author Jelle De Loecker <jelle@develry.be>
28
+ * @author Jelle De Loecker <jelle@elevenways.be>
38
29
  * @since 0.2.0
39
- * @version 0.2.0
30
+ * @version 1.0.0
40
31
  *
41
- * @return {Boolean}
32
+ * @return {FieldSet}
42
33
  */
43
- ChimeraConfig.setMethod(function containsTranslations() {
44
-
45
- for (key in this.ModelClass.blueprint) {
46
- if (this.ModelClass.blueprint[key].translatable) {
47
- return true;
48
- }
49
- }
50
-
51
- return false;
34
+ Config.setMethod(function getActionFields(name) {
35
+ return this.getFieldSet(name);
52
36
  });
53
37
 
54
38
  /**
55
- * Get the fields to show in the index
39
+ * Get a named fieldset
56
40
  *
57
- * @author Jelle De Loecker <jelle@develry.be>
41
+ * @author Jelle De Loecker <jelle@elevenways.be>
58
42
  * @since 0.2.0
59
- * @version 0.2.0
43
+ * @version 1.0.0
60
44
  *
61
- * @return {Array}
45
+ * @return {FieldSet}
62
46
  */
63
- ChimeraConfig.setMethod(function getIndexFields() {
64
-
65
- var modelName,
66
- fields = [],
67
- key;
68
-
69
- modelName = this.ModelClass.prototype.name;
70
-
71
- return this.ModelClass.blueprint.getSorted();
72
-
73
- for (key in this.ModelClass.blueprint) {
74
- fields.push({field: modelName + '.' + key, config: this.ModelClass.blueprint[key]});
75
- }
76
-
77
- if (this.containsTranslations()) {
78
- fields.push({meta: 'translations'});
79
- }
80
-
81
- return fields;
82
- });
83
-
84
- /**
85
- * Get the fieldgroup for a specific action
86
- *
87
- * @author Jelle De Loecker <jelle@develry.be>
88
- * @since 0.2.0
89
- * @version 0.3.0
90
- *
91
- * @return {Deck}
92
- */
93
- ChimeraConfig.setMethod(function getActionFields(name) {
94
-
95
- var group;
47
+ Config.setMethod(function getFieldSet(name) {
96
48
 
97
49
  if (name == null) {
98
50
  throw new Error('No action group name was given');
99
51
  }
100
52
 
101
- if (this.actionGroups[name] == null) {
102
- group = new Classes.Alchemy.ChimeraActionFields(this.ModelClass, name);
103
- this.actionGroups[name] = group;
104
- } else {
105
- group = this.actionGroups[name];
106
- }
53
+ let set = this.field_sets[name];
107
54
 
108
- return group;
109
- });
110
-
111
- /**
112
- * Get the fields to show in the given type
113
- *
114
- * @author Jelle De Loecker <jelle@develry.be>
115
- * @since 0.2.0
116
- * @version 0.2.0
117
- *
118
- * @return {Array}
119
- */
120
- ChimeraConfig.setMethod(function getFields(type) {
121
-
122
- var fields;
123
-
124
- fields = this.ModelClass.blueprint.getSorted();
55
+ if (!set) {
56
+ set = new Classes.Alchemy.Criteria.FieldSet(name, this.ModelClass);
57
+ this.field_sets[name] = set;
58
+ }
125
59
 
126
- return this.ModelClass.blueprint.clone();
60
+ return set;
127
61
  });
128
62
 
129
63
  /**
130
- * Get a specific field
64
+ * Get the widget configuration for the given action
131
65
  *
132
- * @author Jelle De Loecker <jelle@develry.be>
133
- * @since 0.2.0
134
- * @version 0.4.0
66
+ * @author Jelle De Loecker <jelle@elevenways.be>
67
+ * @since 1.0.0
68
+ * @version 1.0.2
135
69
  *
136
- * @param {String} actionName Like edit, list, ...
137
- * @param {String} fieldName Fieldname path
138
- * @param {Object} record Optional record
70
+ * @param {String} action
71
+ * @param {Conduit} conduit
139
72
  *
140
- * @return {ChimeraField}
73
+ * @return {Object}
141
74
  */
142
- ChimeraConfig.setMethod(function getField(actionName, fieldName, record) {
143
-
144
- var actionFields,
145
- subschema,
146
- subrecord,
147
- next_name,
148
- pieces,
149
- field,
150
- first,
151
- temp;
152
-
153
- if (fieldName == null || typeof fieldName == 'object') {
154
- record = fieldName;
155
- fieldName = actionName;
156
- actionName = 'edit';
157
- }
158
-
159
- pieces = fieldName.split('.');
160
-
161
- // Remove the first piece if it's just this model name
162
- if (pieces[0] == this.ModelClass.model_name) {
163
- pieces.shift();
164
- }
165
-
166
- first = pieces.shift();
167
- next_name = first;
75
+ Config.setMethod(function getWidgetConfig(action, conduit) {
168
76
 
169
- // If the action group isn't defined,
170
- // get nothing
171
- if (this.actionGroups[actionName] == null) {
172
- return;
173
- }
77
+ let fieldset,
78
+ widgets;
174
79
 
175
- field = this.actionGroups[actionName].getField(first);
80
+ // @TODO: get the possible user-modified widget config!
176
81
 
177
- // We might need to get something out of the record, too
178
- subrecord = record;
82
+ let result = {};
179
83
 
180
- while (pieces.length > 0) {
84
+ if (action == 'edit') {
85
+ fieldset = this.getFieldSet('edit');
181
86
 
182
- // Get the subschema of this field
183
- subschema = field.fieldType.getSubschema(subrecord, next_name);
87
+ let field_widgets = [];
184
88
 
185
- if (!subschema) {
186
- return;
187
- }
89
+ let field;
188
90
 
189
- // Create a new actionfields object
190
- actionFields = new Classes.Alchemy.ChimeraActionFields(subschema, actionName);
91
+ for (field of fieldset) {
191
92
 
192
- // Get the next fieldname to get
193
- next_name = pieces.shift();
194
-
195
- // If this field was a subschema, change the subrecord too
196
- if (field.fieldType.type_name == 'schema') {
197
- subrecord = Object.path(subrecord, field.path);
93
+ field_widgets.push({
94
+ type : 'alchemy_field',
95
+ config : {
96
+ field : field.name,
97
+ view : field.options.view,
98
+ widget_settings : field.options.widget_settings || {},
99
+ }
100
+ });
198
101
  }
199
102
 
200
- // @TODO: When encountering numbers,
201
- // it's probably an arrayable field,
202
- // and we can't use that to get the actual field definition
203
- if (Number.isInteger(Number(next_name))) {
204
-
205
- if (Array.isArray(subrecord)) {
206
- subrecord = subrecord[next_name];
103
+ field_widgets.push({
104
+ type : 'html',
105
+ config : {
106
+ html : '<button class="btn btn-submit" type="submit">Save</button>'
207
107
  }
108
+ });
109
+
110
+ widgets = [
111
+ {
112
+ "type": "column",
113
+ "config": {
114
+ "widgets": [
115
+ {
116
+ "type": "header",
117
+ "config": {
118
+ "level": 1,
119
+ "content": this.ModelClass.title + ' edit',
120
+ }
121
+ },
122
+ {
123
+ type: "row",
124
+ config: {
125
+ widgets: [
126
+ {
127
+ type: "column",
128
+ config: {
129
+ widgets: [
130
+ {
131
+ "type": "alchemy_form",
132
+ "config": {
133
+ model : this.ModelClass.type_name,
134
+ view_type : 'edit',
135
+ widgets : field_widgets
136
+ }
137
+ }
138
+ ]
139
+ }
140
+ },
141
+ {
142
+ type: 'column',
143
+ config: {
144
+ wrapper_class_names: 'toc-col',
145
+ widgets: [
146
+ {
147
+ type: "table_of_contents",
148
+ config: {
149
+ parent_selector: 'alchemy-widgets-row',
150
+ elements_selector: 'alchemy-field',
151
+ title_selector: 'alchemy-label'
152
+ }
153
+ }
154
+ ]
155
+ }
156
+ }
157
+ ]
158
+ }
159
+ }
160
+ ]
161
+ }
162
+ }
163
+ ];
208
164
 
209
- // It was a number, skip to the next piece
210
- next_name = pieces.shift();
211
- }
212
-
213
- // Add the field to get to the actionfields,
214
- // so it can init everything it needs to init
215
- actionFields.addField(next_name);
216
-
217
- // Get the inited chimerafield we just added
218
- field = actionFields.getField(next_name);
165
+ } else {
166
+ fieldset = this.getFieldSet('list');
167
+
168
+ widgets = [
169
+ {
170
+ "type": "column",
171
+ "config": {
172
+ "widgets": [
173
+ {
174
+ "type": "alchemy_table",
175
+ "config": {
176
+ fieldset : fieldset,
177
+ page_size : 50,
178
+ show_filters : true,
179
+ id : 'aft-' + this.ModelClass.type_name,
180
+ recordsource : {
181
+ route : 'Chimera.Editor#records',
182
+ parameters : {
183
+ model : this.ModelClass.type_name
184
+ }
185
+ }
186
+ }
187
+ }
188
+ ]
189
+ }
190
+ }
191
+ ];
219
192
  }
220
193
 
221
- return field;
194
+ result.widgets = widgets;
195
+
196
+ return result;
222
197
  });
package/model/model.js CHANGED
@@ -9,7 +9,7 @@
9
9
  * @type {Alchemy.ChimeraConfig}
10
10
  */
11
11
  Model.prepareStaticProperty(function chimera() {
12
- return new Classes.Alchemy.ChimeraConfig(this);
12
+ return new Classes.Alchemy.Chimera.Config(this);
13
13
  });
14
14
 
15
15
  /**
package/package.json CHANGED
@@ -1,27 +1,23 @@
1
1
  {
2
2
  "name": "alchemy-chimera",
3
3
  "description": "Chimera plugin for Alchemy MVC",
4
- "version": "0.5.4",
5
- "author": "Jelle De Loecker <jelle@develry.be>",
4
+ "version": "1.0.2",
5
+ "author": "Jelle De Loecker <jelle@elevenways.be>",
6
6
  "keywords": [
7
7
  "alchemy",
8
8
  "alchemymvc",
9
9
  "plugin",
10
10
  "cms"
11
11
  ],
12
- "repository": "skerit/alchemy-chimera",
13
- "dependencies": {
14
- "alchemy-ajatar-theme" : "~1.1.4",
15
- "excel-export" : "0.3.11",
16
- "msexcel-builder" : "0.0.x"
17
- },
12
+ "repository": "11ways/alchemy-chimera",
18
13
  "peerDependencies": {
19
- "alchemymvc": "~1.0.6",
20
- "alchemy-acl": "~0.5.4",
21
- "alchemy-menu": "~0.5.0"
14
+ "alchemy-acl" : "~0.7.0",
15
+ "alchemy-menu" : "~0.6.0",
16
+ "alchemymvc" : "~1.1.0",
17
+ "alchemy-widget": "~0.1.0"
22
18
  },
23
19
  "license": "MIT",
24
20
  "engines": {
25
- "node": ">=8.9.0"
21
+ "node" : ">=12.0.0"
26
22
  }
27
23
  }
@@ -0,0 +1,8 @@
1
+ {% extend "layouts/chimera_body" %}
2
+
3
+ {% block "main" %}
4
+ Dashboard Widgets:
5
+ <alchemy-widgets>
6
+
7
+ </alchemy-widgets>
8
+ {% /block %}
@@ -0,0 +1,20 @@
1
+ {% include "layouts/chimera_basics" %}
2
+
3
+ {% block "main" %}
4
+ <alchemy-widgets
5
+ class="main-widgets"
6
+ #context_variables={% context_variables %}
7
+ #value={% widget_config %}
8
+ ></alchemy-widgets>
9
+ {% /block %}
10
+
11
+ {% block "page-actions" %}
12
+ <a
13
+ !Route="Chimera.Editor#add"
14
+ #model={% model_name %}
15
+ class="btn"
16
+ >
17
+ <al-ico type="plus"></al-ico>
18
+ {%t "new" model=model_name %}
19
+ </a>
20
+ {% /block %}
@@ -0,0 +1,4 @@
1
+ <alchemy-widgets
2
+ class="sidebar-widgets"
3
+ #value=<% navigation_widgets %>
4
+ ></alchemy-widgets>
@@ -0,0 +1,8 @@
1
+ {% include "layouts/chimera_basics" %}
2
+
3
+ {% block "main" %}
4
+ <alchemy-widgets
5
+ #context_variables={% context_variables %}
6
+ #value={% widget_config %}
7
+ ></alchemy-widgets>
8
+ {% /block %}
@@ -0,0 +1,15 @@
1
+ <!DOCTYPE html>
2
+ <html>
3
+ <head>
4
+ <!-- This puts in all the required styles, scripts, ... -->
5
+ <% this.foundation({protoblast: true}) %>
6
+ <% script('chimera/chimera') %>
7
+ </head>
8
+ <body>
9
+ <!-- This is a block you can assign content to -->
10
+ <he-block data-he-name="base"></he-block>
11
+
12
+ <!-- This is an internal element you should not worry about -->
13
+ <he-bottom></he-bottom>
14
+ </body>
15
+ </html>
@@ -0,0 +1,15 @@
1
+ {% extend "layouts/chimera_body" %}
2
+
3
+ {% if page_title %}
4
+ {% block "page-title" %}{{ page_title }}{% /block %}
5
+ {% /if %}
6
+
7
+ {% if window_title %}
8
+ <% set_title(window_title) %>
9
+ {% elseif page_title %}
10
+ <% set_title(page_title) %>
11
+ {% /if %}
12
+
13
+ {% if message %}
14
+ {% block "page-notification" %}<span class="notification">{{ message }}</span>{% /block %}
15
+ {% /if %}
@@ -0,0 +1,24 @@
1
+ {% extend "layouts/chimera_base" %}
2
+
3
+ <% style('chimera/chimera') %>
4
+
5
+ {% block "base" %}
6
+ <div class="chimera-wrapper">
7
+ <div class="chimera-sidebar">
8
+ <div class="chimera-page-header">
9
+
10
+ </div>
11
+ <%= Alchemy.segment('Chimera.Static#sidebar') %>
12
+ </div>
13
+ <div class="chimera-content">
14
+ <div class="chimera-page-header">
15
+ <div class="page-title" data-he-name="page-title"></div>
16
+ <div class="page-notification" data-he-name="page-notification"></div>
17
+ <div class="page-actions" data-he-name="page-actions"></div>
18
+ </div>
19
+ <div data-he-name="main" class="chimera-main">
20
+
21
+ </div>
22
+ </div>
23
+ </div>
24
+ {% /block %}