mirror of
https://github.com/documize/community.git
synced 2025-08-05 05:25:27 +02:00
upgraded Ember and integrated Bootstrap 4
Upgraded to Ember JS 2.16.x release. This upgrade uses the new JavaScript modules API syntax. Integrated Bootstrap 4 Beta 2 via package.json and associated popper.js library. Overridden Bootstrap styles using bootstrap.scss -- this file selectively imports the modules we need.
This commit is contained in:
parent
0f04be4ea1
commit
b31ab712c1
229 changed files with 1610 additions and 3181 deletions
|
@ -9,9 +9,9 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import Ember from 'ember';
|
||||
import constants from '../utils/constants';
|
||||
|
||||
export default Model.extend({
|
||||
|
@ -24,7 +24,7 @@ export default Model.extend({
|
|||
activityType: attr('number'),
|
||||
created: attr(),
|
||||
|
||||
activityLabel: Ember.computed('activityType', function() {
|
||||
activityLabel: computed('activityType', function() {
|
||||
let label = '';
|
||||
|
||||
switch (this.get('activityType')) {
|
||||
|
@ -62,7 +62,7 @@ export default Model.extend({
|
|||
return label;
|
||||
}),
|
||||
|
||||
activityColor: Ember.computed('activityType', function() {
|
||||
activityColor: computed('activityType', function() {
|
||||
let color = '';
|
||||
|
||||
switch (this.get('activityType')) {
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import Ember from 'ember';
|
||||
import stringUtil from '../utils/string';
|
||||
// import { belongsTo, hasMany } from 'ember-data/relationships';
|
||||
|
||||
|
@ -29,7 +29,7 @@ export default Model.extend({
|
|||
|
||||
// client-side property
|
||||
selected: attr('boolean', { defaultValue: false }),
|
||||
slug: Ember.computed('name', function () {
|
||||
slug: computed('name', function () {
|
||||
return stringUtil.makeSlug(this.get('name'));
|
||||
}),
|
||||
created: attr(),
|
||||
|
|
|
@ -9,11 +9,11 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import constants from '../utils/constants';
|
||||
import stringUtil from '../utils/string';
|
||||
import Ember from 'ember';
|
||||
// import { belongsTo, hasMany } from 'ember-data/relationships';
|
||||
|
||||
export default Model.extend({
|
||||
|
@ -22,7 +22,7 @@ export default Model.extend({
|
|||
userId: attr('string'),
|
||||
folderType: attr('number', { defaultValue: 2 }),
|
||||
|
||||
slug: Ember.computed('name', function () {
|
||||
slug: computed('name', function () {
|
||||
return stringUtil.makeSlug(this.get('name'));
|
||||
}),
|
||||
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import Ember from 'ember';
|
||||
// import { hasMany } from 'ember-data/relationships';
|
||||
|
||||
export default Model.extend({
|
||||
|
@ -28,21 +28,21 @@ export default Model.extend({
|
|||
rawBody: attr('string'),
|
||||
meta: attr(),
|
||||
|
||||
tagName: Ember.computed('level', function () {
|
||||
tagName: computed('level', function () {
|
||||
return "h2";
|
||||
// return "h" + (this.get('level') + 1);
|
||||
}),
|
||||
|
||||
tocIndent: Ember.computed('level', function () {
|
||||
tocIndent: computed('level', function () {
|
||||
return (this.get('level') - 1) * 20;
|
||||
}),
|
||||
|
||||
tocIndentCss: Ember.computed('tocIndent', function () {
|
||||
tocIndentCss: computed('tocIndent', function () {
|
||||
let tocIndent = this.get('tocIndent');
|
||||
return `margin-left-${tocIndent}`;
|
||||
}),
|
||||
|
||||
hasRevisions: Ember.computed('revisions', function () {
|
||||
hasRevisions: computed('revisions', function () {
|
||||
return this.get('revisions') > 0;
|
||||
}),
|
||||
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import Ember from 'ember';
|
||||
// import { belongsTo, hasMany } from 'ember-data/relationships';
|
||||
|
||||
export default Model.extend({
|
||||
|
@ -23,7 +23,7 @@ export default Model.extend({
|
|||
folderId: attr('string'),
|
||||
folderType: attr('number', { defaultValue: 0 }),
|
||||
|
||||
fullname: Ember.computed('firstname', 'lastname', function () {
|
||||
fullname: computed('firstname', 'lastname', function () {
|
||||
return `${this.get('firstname')} ${this.get('lastname')}`;
|
||||
})
|
||||
});
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import Ember from 'ember';
|
||||
// import { belongsTo, hasMany } from 'ember-data/relationships';
|
||||
|
||||
export default Model.extend({
|
||||
|
@ -22,7 +22,7 @@ export default Model.extend({
|
|||
iconFont: attr('string'),
|
||||
iconFile: attr('string'),
|
||||
|
||||
hasImage: Ember.computed('iconFont', 'iconFile', function () {
|
||||
hasImage: computed('iconFont', 'iconFile', function () {
|
||||
return this.get('iconFile').length > 0;
|
||||
}),
|
||||
|
||||
|
|
|
@ -9,10 +9,10 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import stringUtil from '../utils/string';
|
||||
import Ember from 'ember';
|
||||
// import { belongsTo, hasMany } from 'ember-data/relationships';
|
||||
|
||||
export default Model.extend({
|
||||
|
@ -22,7 +22,7 @@ export default Model.extend({
|
|||
title: attr('string'),
|
||||
type: attr('number', { defaultValue: 0 }),
|
||||
|
||||
slug: Ember.computed('title', function () {
|
||||
slug: computed('title', function () {
|
||||
return stringUtil.makeSlug(this.get('title'));
|
||||
}),
|
||||
created: attr(),
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import Ember from 'ember';
|
||||
|
||||
export default Model.extend({
|
||||
documentName: attr('string'),
|
||||
|
@ -20,13 +20,13 @@ export default Model.extend({
|
|||
viewed: attr('string'),
|
||||
created: attr('string'),
|
||||
|
||||
hasContributed: Ember.computed('contributed', function () {
|
||||
hasContributed: computed('contributed', function () {
|
||||
return this.get('contributed').length > 0;
|
||||
}),
|
||||
hasViewed: Ember.computed('viewed', function () {
|
||||
hasViewed: computed('viewed', function () {
|
||||
return this.get('viewed').length > 0;
|
||||
}),
|
||||
hasCreated: Ember.computed('created', function () {
|
||||
hasCreated: computed('created', function () {
|
||||
return this.get('created').length > 0;
|
||||
})
|
||||
});
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
//
|
||||
// https://documize.com
|
||||
|
||||
import { computed } from '@ember/object';
|
||||
import Model from 'ember-data/model';
|
||||
import attr from 'ember-data/attr';
|
||||
import Ember from 'ember';
|
||||
// import { belongsTo, hasMany } from 'ember-data/relationships';
|
||||
|
||||
export default Model.extend({
|
||||
|
@ -28,7 +28,7 @@ export default Model.extend({
|
|||
created: attr(),
|
||||
revised: attr(),
|
||||
|
||||
fullname: Ember.computed('firstname', 'lastname', function () {
|
||||
fullname: computed('firstname', 'lastname', function () {
|
||||
return `${this.get('firstname')} ${this.get('lastname')}`;
|
||||
}),
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue