Skip to content

Commit

Permalink
Upgrade UI framework to Ember v3.10.0
Browse files Browse the repository at this point in the history
  • Loading branch information
HarveyKandola committed May 16, 2019
1 parent 49bf4ee commit 479508e
Show file tree
Hide file tree
Showing 22 changed files with 68,649 additions and 1,738 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ All you need to provide is PostgreSQL, Microsoft SQL Server or any MySQL variant
## Technology Stack

- Go (v1.12.5)
- Ember JS (v3.8.0)
- Ember JS (v3.10.0)

## Authentication Options

Expand Down
2,327 changes: 1,036 additions & 1,291 deletions embed/bindata.go

Large diffs are not rendered by default.

15 changes: 13 additions & 2 deletions gui/.eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,10 @@ module.exports = {
'.template-lintrc.js',
'ember-cli-build.js',
'testem.js',
'config/**/*.js'
'blueprints/*/index.js',
'config/**/*.js',
'lib/*/index.js',
'server/**/*.js'
],
parserOptions: {
sourceType: 'script',
Expand All @@ -42,7 +45,15 @@ module.exports = {
excludedFiles: ['tests/dummy/**/*.js'],
env: {
embertest: true
}
},
plugins: ['node'],
rules: Object.assign({}, require('eslint-plugin-node').configs.recommended.rules, {
// add your custom rules and overrides for node files here

// this can be removed once the following is fixed
// https://github.com/mysticatea/eslint-plugin-node/issues/77
'node/no-unpublished-require': 'off'
})
}
],
globals: {
Expand Down
1 change: 0 additions & 1 deletion gui/.template-lintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ module.exports = {
'no-invalid-interactive': false,
'no-nested-interactive': false,
'no-triple-curlies': false,
'no-global-jquery': false,
'style-concatenation': false,
'simple-unless': false,
}
Expand Down
9 changes: 6 additions & 3 deletions gui/app/components/customize/auth-settings.js
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,12 @@ export default Component.extend(ModalMixin, Notifier, {
this.set('ldapPreview', {isError: true, message: 'Unable to connect'});

switch (provider) {
case constants.AuthProvider.Documize:
case constants.AuthProvider.Documize: {
// nothing to do
break;
}

case constants.AuthProvider.Keycloak: // eslint-disable-line no-case-declarations
case constants.AuthProvider.Keycloak: {
let config = this.get('authConfig');

if (_.isUndefined(config) || _.isNull(config) || _.isEmpty(config) ) {
Expand All @@ -103,8 +104,9 @@ export default Component.extend(ModalMixin, Notifier, {

this.set('keycloakConfig', config);
break;
}

case constants.AuthProvider.LDAP: // eslint-disable-line no-case-declarations
case constants.AuthProvider.LDAP: {
let ldapConfig = this.get('authConfig');

if (_.isUndefined(ldapConfig) || _.isNull(ldapConfig) || _.isEmpty(ldapConfig) ) {
Expand All @@ -118,6 +120,7 @@ export default Component.extend(ModalMixin, Notifier, {

this.set('ldapConfig', ldapConfig);
break;
}
}
},

Expand Down
9 changes: 4 additions & 5 deletions gui/app/components/customize/user-list.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
// https://documize.com

import $ from 'jquery';
import { observer } from '@ember/object';
import { inject as service } from '@ember/service';
import { schedule, debounce } from '@ember/runloop';
import AuthProvider from '../../mixins/auth';
Expand Down Expand Up @@ -51,15 +50,15 @@ export default Component.extend(AuthProvider, ModalMixin, Notifier, {
this.set('users', users);
},

onKeywordChange: observer('filter', function() {
debounce(this, this.filterUsers, 350);
}),

filterUsers() {
this.get('onFilter')(this.get('filter'));
},

actions: {
onFilterChange() {
debounce(this, this.filterUsers, 350);
},

togglePerms() {
this.set('showPermExplain', !this.get('showPermExplain'));

Expand Down
1 change: 1 addition & 0 deletions gui/app/components/document/add-section.js
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ export default Component.extend(Notifier, Modals, {
return this.get('blocks.length') > 0;
}),

// eslint-disable-next-line ember/no-observers
onModalToggle: observer('show', function() {
let modalId = this.get('modalId');

Expand Down
3 changes: 3 additions & 0 deletions gui/app/components/document/page-heading.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,12 @@ export default Component.extend(ModalMixin, {
canDelete: false,
canMove: false,
docSearchFilter: '',

// eslint-disable-next-line ember/no-observers
onKeywordChange: observer('docSearchFilter', function() {
debounce(this, this.searchDocs, 750);
}),

emptySearch: computed('docSearchResults', function() {
return this.get('docSearchResults.length') === 0;
}),
Expand Down
1 change: 1 addition & 0 deletions gui/app/components/section/flowchart/type-editor.js
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ export default Component.extend({
), '*');
},

// eslint-disable-next-line ember/no-observers
goSave: observer('readyToSave', function() {
if (this.get('readyToSave')) {
let page = this.get('page');
Expand Down
2 changes: 1 addition & 1 deletion gui/app/templates/components/customize/user-list.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
{{ui/ui-spacer size=300}}

<div class="form-group">
{{focus-input type="text" class="form-control" placeholder="filter users" value=filter}}
{{focus-input type="text" class="form-control" placeholder="filter users" value=filter key-up=(action "onFilterChange")}}
<small class="form-text text-muted">search firstname, lastname, email</small>
</div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<div class="document-sidebar-attachment">
<ul class="files">
{{#each files key="id" as |file|}}
{{#if (eq file.pageId '')}}
{{#if (eq file.pageId "")}}
<li class="file">
<a href="{{appMeta.endpoint}}/public/attachment/{{appMeta.orgId}}/{{file.id}}{{downloadQuery}}">
{{file.filename}}
Expand Down
6 changes: 3 additions & 3 deletions gui/app/templates/components/section/pdf/type-editor.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,13 @@
<div class="form-group">
<label for="new-space-name">Sidebar</label>
<select onchange={{action "onSetSidebar" value="target.value"}} class="form-control">
<option value="none" selected={{is-equal pdfOption.sidebar 'none'}}>
<option value="none" selected={{is-equal pdfOption.sidebar "none"}}>
None
</option>
<option value="bookmarks" selected={{is-equal pdfOption.sidebar 'bookmarks'}}>
<option value="bookmarks" selected={{is-equal pdfOption.sidebar "bookmarks"}}>
Bookmarks
</option>
<option value="thumbs" selected={{is-equal pdfOption.sidebar 'thumbs'}}>
<option value="thumbs" selected={{is-equal pdfOption.sidebar "thumbs"}}>
Thumbnails
</option>
</select>
Expand Down
1 change: 1 addition & 0 deletions gui/app/utils/string.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/* eslint-disable no-useless-escape */
// Copyright 2016 Documize Inc. <[email protected]>. All rights reserved.
//
// This software (Documize Community Edition) is licensed under
Expand Down
32 changes: 16 additions & 16 deletions gui/package.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
{
"name": "documize",
"version": "2.5.0",
"version": "2.5.1",
"description": "The Document IDE",
"repository": "",
"license": "AGPL",
"author": "Documize Inc.",
"author": "Documize",
"directories": {
"doc": "doc",
"test": "tests"
Expand All @@ -26,42 +26,42 @@
"broccoli-asset-rev": "^3.0.0",
"ember-ajax": "^3.1.0",
"ember-attacher": "^0.13.10",
"ember-cli": "~3.8.0",
"ember-cli": "~3.10.0",
"ember-cli-app-version": "^3.2.0",
"ember-cli-babel": "^7.5.0",
"ember-cli-babel": "^7.7.3",
"ember-cli-dependency-checker": "^3.1.0",
"ember-cli-eslint": "^5.1.0",
"ember-cli-htmlbars": "^3.0.0",
"ember-cli-htmlbars": "^3.0.1",
"ember-cli-htmlbars-inline-precompile": "^2.1.0",
"ember-cli-inject-live-reload": "^2.0.1",
"ember-cli-mirage": "^0.4.15",
"ember-cli-sass": "10.0.0",
"ember-cli-sri": "^2.1.1",
"ember-cli-template-lint": "^1.0.0-beta.1",
"ember-cli-uglify": "^2.1.0",
"ember-cli-update": "^0.30.0",
"ember-concurrency": "^0.8.27",
"ember-data": "~3.8.0",
"ember-cli-uglify": "^3.0.0",
"ember-cli-update": "^0.34.7",
"ember-concurrency": "^0.10.0",
"ember-data": "~3.10.0",
"ember-export-application-global": "^2.0.0",
"ember-load-initializers": "^2.0.0",
"ember-maybe-import-regenerator": "^0.1.6",
"ember-qunit": "^4.4.1",
"ember-resolver": "^5.1.3",
"ember-simple-auth": "^1.8.1",
"ember-source": "~3.8.0",
"ember-simple-auth": "^1.8.2",
"ember-source": "~3.10.0",
"ember-toggle": "^5.3.2",
"ember-truth-helpers": "^2.1.0",
"eslint": "^5.14.1",
"eslint-plugin-ember": "^6.2.0",
"eslint-plugin-ember": "^6.4.1",
"eslint-plugin-node": "^8.0.1",
"loader.js": "^4.7.0",
"qunit-dom": "^0.8.4"
"qunit-dom": "^0.8.5"
},
"dependencies": {
"bootstrap": "^4.2.1",
"nan": "git+https://github.com/nodejs/nan.git",
"node-sass": "^4.12.0",
"npm": "^6.7.0",
"npm": "^6.9.0",
"pdfjs-dist": "^2.0.943",
"popper.js": "^1.14.7"
"popper.js": "^1.15.0"
}
}
Loading

0 comments on commit 479508e

Please sign in to comment.