@concretecms/bedrock 1.1.0 → 1.1.4

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 (30) hide show
  1. package/.idea/bedrock.iml +8 -0
  2. package/.idea/codeStyles/Project.xml +48 -0
  3. package/.idea/codeStyles/codeStyleConfig.xml +5 -0
  4. package/.idea/inspectionProfiles/Project_Default.xml +7 -0
  5. package/.idea/modules.xml +8 -0
  6. package/.idea/vcs.xml +6 -0
  7. package/assets/bedrock/scss/_frontend.scss +1 -0
  8. package/assets/bedrock/scss/_theme-context-root.scss +17 -0
  9. package/assets/bedrock/scss/_theme-grid.scss +4 -2
  10. package/assets/cms/components/customizer/FontFamilyPageCustomizerWidget.vue +3 -3
  11. package/assets/cms/components/customizer/ThemeCustomizer.vue +2 -2
  12. package/assets/cms/components/file-manager/Chooser/FileManager.vue +75 -72
  13. package/assets/cms/components/file-manager/Chooser/FileSets.vue +11 -7
  14. package/assets/cms/components/file-manager/Chooser/FileUpload.vue +3 -1
  15. package/assets/cms/components/file-manager/Chooser/Files.vue +38 -4
  16. package/assets/cms/components/file-manager/Chooser/FolderBookmark.vue +4 -0
  17. package/assets/cms/components/file-manager/Chooser/RecentUploads.vue +4 -0
  18. package/assets/cms/components/file-manager/Chooser/SavedSearch.vue +11 -7
  19. package/assets/cms/components/file-manager/Chooser/Search.vue +13 -8
  20. package/assets/cms/components/file-manager/Chooser.vue +18 -0
  21. package/assets/cms/components/file-manager/Uploader/UploadFromComputer.vue +3 -2
  22. package/assets/cms/components/file-manager/Uploader.vue +1 -0
  23. package/assets/cms/components/form/ConcreteFileInput.vue +8 -1
  24. package/assets/cms/components/form/ConcreteThemeColorInput.vue +1 -1
  25. package/assets/cms/js/edit-mode/layouts.js +4 -4
  26. package/assets/cms/js/file-manager/file-manager.js +1 -8
  27. package/assets/cms/scss/_toolbar.scss +1 -0
  28. package/assets/cms/scss/bootstrap/_reboot.scss +0 -29
  29. package/assets/imagery/scss/frontend/_hero-image.scss +7 -0
  30. package/package.json +2 -2
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="WEB_MODULE" version="4">
3
+ <component name="NewModuleRootManager">
4
+ <content url="file://$MODULE_DIR$" />
5
+ <orderEntry type="inheritedJdk" />
6
+ <orderEntry type="sourceFolder" forTests="false" />
7
+ </component>
8
+ </module>
@@ -0,0 +1,48 @@
1
+ <component name="ProjectCodeStyleConfiguration">
2
+ <code_scheme name="Project" version="173">
3
+ <PHPCodeStyleSettings>
4
+ <option name="BLANK_LINES_BETWEEN_IMPORTS" value="1" />
5
+ <option name="LOWER_CASE_BOOLEAN_CONST" value="true" />
6
+ <option name="LOWER_CASE_NULL_CONST" value="true" />
7
+ <option name="ELSE_IF_STYLE" value="COMBINE" />
8
+ <option name="KEEP_RPAREN_AND_LBRACE_ON_ONE_LINE" value="true" />
9
+ <option name="BLANK_LINES_AFTER_OPENING_TAG" value="1" />
10
+ <option name="KEEP_BLANK_LINES_AFTER_LBRACE" value="0" />
11
+ <option name="NEW_LINE_AFTER_PHP_OPENING_TAG" value="true" />
12
+ </PHPCodeStyleSettings>
13
+ <codeStyleSettings language="JavaScript">
14
+ <option name="INDENT_CASE_FROM_SWITCH" value="false" />
15
+ <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
16
+ <option name="ALIGN_MULTILINE_FOR" value="false" />
17
+ </codeStyleSettings>
18
+ <codeStyleSettings language="PHP">
19
+ <option name="KEEP_BLANK_LINES_BEFORE_RBRACE" value="0" />
20
+ <option name="BLANK_LINES_AFTER_PACKAGE" value="1" />
21
+ <option name="ALIGN_MULTILINE_PARAMETERS" value="false" />
22
+ <option name="ALIGN_MULTILINE_PARAMETERS_IN_CALLS" value="true" />
23
+ <option name="ALIGN_MULTILINE_EXTENDS_LIST" value="true" />
24
+ <option name="CALL_PARAMETERS_WRAP" value="5" />
25
+ <option name="CALL_PARAMETERS_LPAREN_ON_NEXT_LINE" value="true" />
26
+ <option name="CALL_PARAMETERS_RPAREN_ON_NEXT_LINE" value="true" />
27
+ <option name="METHOD_PARAMETERS_WRAP" value="5" />
28
+ <option name="METHOD_PARAMETERS_LPAREN_ON_NEXT_LINE" value="true" />
29
+ <option name="METHOD_PARAMETERS_RPAREN_ON_NEXT_LINE" value="true" />
30
+ <option name="EXTENDS_LIST_WRAP" value="5" />
31
+ <option name="FOR_STATEMENT_LPAREN_ON_NEXT_LINE" value="true" />
32
+ <option name="FOR_STATEMENT_RPAREN_ON_NEXT_LINE" value="true" />
33
+ <option name="ARRAY_INITIALIZER_WRAP" value="5" />
34
+ <option name="ARRAY_INITIALIZER_LBRACE_ON_NEXT_LINE" value="true" />
35
+ <option name="ARRAY_INITIALIZER_RBRACE_ON_NEXT_LINE" value="true" />
36
+ <option name="IF_BRACE_FORCE" value="3" />
37
+ <option name="DOWHILE_BRACE_FORCE" value="3" />
38
+ <option name="WHILE_BRACE_FORCE" value="3" />
39
+ <option name="FOR_BRACE_FORCE" value="3" />
40
+ </codeStyleSettings>
41
+ <codeStyleSettings language="Vue">
42
+ <indentOptions>
43
+ <option name="INDENT_SIZE" value="4" />
44
+ <option name="TAB_SIZE" value="4" />
45
+ </indentOptions>
46
+ </codeStyleSettings>
47
+ </code_scheme>
48
+ </component>
@@ -0,0 +1,5 @@
1
+ <component name="ProjectCodeStyleConfiguration">
2
+ <state>
3
+ <option name="USE_PER_PROJECT_SETTINGS" value="true" />
4
+ </state>
5
+ </component>
@@ -0,0 +1,7 @@
1
+ <component name="InspectionProjectProfileManager">
2
+ <profile version="1.0">
3
+ <option name="myName" value="Project Default" />
4
+ <inspection_tool class="Eslint" enabled="true" level="WARNING" enabled_by_default="true" />
5
+ <inspection_tool class="Stylelint" enabled="true" level="ERROR" enabled_by_default="true" />
6
+ </profile>
7
+ </component>
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectModuleManager">
4
+ <modules>
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/bedrock.iml" filepath="$PROJECT_DIR$/.idea/bedrock.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
package/.idea/vcs.xml ADDED
@@ -0,0 +1,6 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
+ </component>
6
+ </project>
@@ -5,6 +5,7 @@
5
5
  @import '@fortawesome/fontawesome-free/scss/variables';
6
6
 
7
7
  // Import Theme Foundation items
8
+ @import 'theme-context-root';
8
9
  @import 'mixins';
9
10
  @import 'utilities';
10
11
  @import 'theme-grid';
@@ -0,0 +1,17 @@
1
+ // What is the purpose of this file, you ask?
2
+ // In our theme color input selector, we use CSS variables to display colors.
3
+ // e.g. var(--bs-primary)
4
+ // However, since .ccm-ui has the CMS variables attached to it, and the ::root has the
5
+ // theme bootstrap variables attached to it, the primary color shown in the color input
6
+ // Will come from .ccm-ui instead of ::root, since .ccm-ui is inside ::root.
7
+ // So instead, let's ALSO define the theme colors against the .ccm-context-theme
8
+ // class, and then wrap any controls that need to have access to theme specific variables
9
+ // within the .ccm-context-theme class.
10
+
11
+ .ccm-context-theme {
12
+
13
+ @each $color, $value in $theme-colors {
14
+ --#{$variable-prefix}#{$color}: #{$value};
15
+ }
16
+
17
+ }
@@ -1,5 +1,7 @@
1
1
  // This file ensures that the layout tools work with this theme grid
2
+ div#ccm-theme-grid-temp,
2
3
  div#ccm-theme-grid-edit-mode-row-wrapper {
3
- display: flex;
4
- width: 100%;
4
+ div.row {
5
+ position: relative; // This is necessary in order for the javascript to correctly use jquery position() calls
6
+ }
5
7
  }
@@ -1,7 +1,7 @@
1
1
  <template>
2
2
  <select @change="componentUpdated" class="selectpicker" v-model="selectedFont">
3
3
  <option value="" :data-content="'<span>Default</span>'">Default</option>
4
- <option v-for="font in webFonts" :value="font" :data-content="'<span style=\'font-family: ' + font + '\'>' + font + '</span>'">{{ font }}</option>
4
+ <option v-for="font in customFonts" :value="font" :data-content="'<span style=\'font-family: ' + font + '\'>' + font + '</span>'">{{ font }}</option>
5
5
  <option v-for="font in standardFonts" :value="font" :data-content="'<span style=\'font-family: ' + font + '\'>' + font + '</span>'">{{ font }}</option>
6
6
  </select>
7
7
  </template>
@@ -42,13 +42,13 @@ export default {
42
42
  }
43
43
  },
44
44
  computed: {
45
- webFonts: function() {
45
+ customFonts: function() {
46
46
  var fonts = []
47
47
  var my = this
48
48
  this.styleValue.style.fonts.forEach(function(font) {
49
49
  fonts.push(font.name)
50
50
  })
51
- if (fonts.indexOf(my.selectedFont) === -1) {
51
+ if (fonts.indexOf(my.selectedFont) === -1 && my.standardFonts.indexOf(my.selectedFont) === -1) {
52
52
  fonts.push(my.selectedFont)
53
53
  }
54
54
  return fonts
@@ -178,7 +178,7 @@ export default {
178
178
  url: my.createNewSkinAction,
179
179
  data: {
180
180
  skinName: my.newSkinName,
181
- styles: my.customizerStyles,
181
+ styles: JSON.stringify(my.customizerStyles),
182
182
  customCss: my.customizerCustomCss,
183
183
  ccm_token: CCM_SECURITY_TOKEN
184
184
  },
@@ -301,7 +301,7 @@ export default {
301
301
  new ConcreteAjaxRequest({
302
302
  url: my.saveSkinAction,
303
303
  data: {
304
- styles: my.customizerStyles,
304
+ styles: JSON.stringify(my.customizerStyles),
305
305
  customCss: my.customizerCustomCss,
306
306
  ccm_token: CCM_SECURITY_TOKEN
307
307
  },
@@ -1,92 +1,95 @@
1
1
  <template>
2
- <div>
3
- <chooser-header :resultsFormFactor.sync="formFactor"
4
- :breadcrumb-items="breadcrumbItems"
5
- @breadcrumbItemClick="activeFolder = $event.folderId"
6
- :title="title"/>
2
+ <div>
3
+ <chooser-header :resultsFormFactor.sync="formFactor"
4
+ :breadcrumb-items="breadcrumbItems"
5
+ @breadcrumbItemClick="activeFolder = $event.folderId"
6
+ :title="title"/>
7
7
 
8
- <files :selectedFiles.sync="selectedFiles"
9
- :resultsFormFactor="formFactor"
10
- :routePath="routePath + activeFolder"
11
- :enable-pagination="true"
12
- :enable-sort="true"
13
- :multipleSelection="multipleSelection"
14
- @folderClick="activeFolder = $event"/>
15
- </div>
8
+ <files :selectedFiles.sync="selectedFiles"
9
+ :resultsFormFactor="formFactor"
10
+ :routePath="routePath + activeFolder"
11
+ :enable-pagination="true"
12
+ :enable-sort="true"
13
+ :filters="filters"
14
+ :multipleSelection="multipleSelection"
15
+ @folderClick="activeFolder = $event"/>
16
+ </div>
16
17
  </template>
17
18
 
18
19
  <script>
19
20
  /* global CCM_DISPATCHER_FILENAME, ConcreteAjaxRequest */
20
- /* eslint indent: [2, 2, {"SwitchCase": 1}] */
21
21
  /* eslint-disable no-new */
22
22
  import ChooserHeader from './Header'
23
23
  import Files from './Files'
24
24
 
25
25
  export default {
26
- components: {
27
- ChooserHeader,
28
- Files
29
- },
30
- data: () => ({
31
- activeFolder: '',
32
- selectedFiles: [],
33
- breadcrumbItems: [],
34
- routePath: '/ccm/system/file/chooser/get_folder_files/',
35
- formFactor: 'grid'
36
- }),
37
- props: {
38
- resultsFormFactor: {
39
- type: String,
40
- required: false,
41
- default: 'grid', // grid | list
42
- validator: value => ['grid', 'list'].indexOf(value) !== -1
26
+ components: {
27
+ ChooserHeader,
28
+ Files
43
29
  },
44
- startFolder: {
45
- type: String,
46
- required: true
30
+ data: () => ({
31
+ activeFolder: '',
32
+ selectedFiles: [],
33
+ breadcrumbItems: [],
34
+ routePath: '/ccm/system/file/chooser/get_folder_files/',
35
+ formFactor: 'grid'
36
+ }),
37
+ props: {
38
+ resultsFormFactor: {
39
+ type: String,
40
+ required: false,
41
+ default: 'grid', // grid | list
42
+ validator: value => ['grid', 'list'].indexOf(value) !== -1
43
+ },
44
+ startFolder: {
45
+ type: String,
46
+ required: true
47
+ },
48
+ title: {
49
+ type: String,
50
+ required: true
51
+ },
52
+ multipleSelection: {
53
+ type: Boolean,
54
+ default: true
55
+ },
56
+ filters: {
57
+ type: Array
58
+ }
47
59
  },
48
- title: {
49
- type: String,
50
- required: true
60
+ created() {
61
+ this.activeFolder = this.$props.startFolder
62
+ this.fetchBreadcrumb(this.activeFolder)
51
63
  },
52
- multipleSelection: {
53
- type: Boolean,
54
- default: true
55
- }
56
- },
57
- created() {
58
- this.activeFolder = this.$props.startFolder
59
- this.fetchBreadcrumb(this.activeFolder)
60
- },
61
- methods: {
62
- fetchBreadcrumb(folderId = '') {
63
- new ConcreteAjaxRequest({
64
- url: `${CCM_DISPATCHER_FILENAME}/ccm/system/file/chooser/get_breadcrumb/${folderId}`,
65
- success: r => {
66
- this.breadcrumbItems = r.data
64
+ methods: {
65
+ fetchBreadcrumb(folderId = '') {
66
+ new ConcreteAjaxRequest({
67
+ url: `${CCM_DISPATCHER_FILENAME}/ccm/system/file/chooser/get_breadcrumb/${folderId}`,
68
+ success: r => {
69
+ this.breadcrumbItems = r.data
70
+ }
71
+ })
67
72
  }
68
- })
69
- }
70
- },
71
- watch: {
72
- activeFolder(value) {
73
- this.fetchBreadcrumb(value)
74
73
  },
75
- selectedFiles(value) {
76
- this.$emit('update:selectedFiles', value)
77
- },
78
- formFactor(value) {
79
- this.$emit('update:resultsFormFactor', value)
74
+ watch: {
75
+ activeFolder(value) {
76
+ this.fetchBreadcrumb(value)
77
+ },
78
+ selectedFiles(value) {
79
+ this.$emit('update:selectedFiles', value)
80
+ },
81
+ formFactor(value) {
82
+ this.$emit('update:resultsFormFactor', value)
83
+ },
84
+ startFolder(value) {
85
+ this.activeFolder = value
86
+ this.fetchBreadcrumb(value)
87
+ }
80
88
  },
81
- startFolder(value) {
82
- this.activeFolder = value
83
- this.fetchBreadcrumb(value)
89
+ mounted() {
90
+ this.formFactor = this.resultsFormFactor
91
+ this.activeFolder = this.$props.startFolder
92
+ this.fetchBreadcrumb(this.activeFolder)
84
93
  }
85
- },
86
- mounted() {
87
- this.formFactor = this.resultsFormFactor
88
- this.activeFolder = this.$props.startFolder
89
- this.fetchBreadcrumb(this.activeFolder)
90
- }
91
94
  }
92
95
  </script>
@@ -10,19 +10,20 @@
10
10
  <select id="fileSetSelector" class="form-select file-set-menu" v-model="activeSet">
11
11
  <option value="" selected>{{ i18n.selectFileSet }}</option>
12
12
  <option v-for="set in sets" :key="set.id" :value="set.id">
13
- {{set.name}}
13
+ {{ set.name }}
14
14
  </option>
15
15
  </select>
16
16
  </div>
17
17
  </div>
18
18
  <div class="mt-3" v-show="activeSet">
19
19
  <files v-if="activeSet"
20
- :selectedFiles.sync="selectedFiles"
21
- :resultsFormFactor="formFactor"
22
- :routePath="routePath + activeSet"
23
- :enable-pagination="true"
24
- :enable-sort="true"
25
- :multipleSelection="multipleSelection"/>
20
+ :selectedFiles.sync="selectedFiles"
21
+ :resultsFormFactor="formFactor"
22
+ :routePath="routePath + activeSet"
23
+ :enable-pagination="true"
24
+ :enable-sort="true"
25
+ :filters="filters"
26
+ :multipleSelection="multipleSelection"/>
26
27
  </div>
27
28
  </div>
28
29
  </template>
@@ -69,6 +70,9 @@ export default {
69
70
  multipleSelection: {
70
71
  type: Boolean,
71
72
  default: true
73
+ },
74
+ filters: {
75
+ type: Array
72
76
  }
73
77
  },
74
78
  methods: {
@@ -2,7 +2,9 @@
2
2
  <div>
3
3
  <chooser-header :show-form-factor-selector="false" :title="title"/>
4
4
 
5
- <uploader/>
5
+ <uploader
6
+ @upload-complete="$emit('upload-complete')"
7
+ />
6
8
  </div>
7
9
  </template>
8
10
 
@@ -9,8 +9,8 @@
9
9
  <label class="form-label" :for="'file-' + (file.fID || file.treeNodeID)"><span v-html="file.resultsThumbnailImg"></span></label>
10
10
  <div class="ccm-image-cell-title pt-1">
11
11
  <div class="form-check form-check-inline">
12
- <input class="form-check-input" type="checkbox" v-if="multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
13
- <input class="form-check-input" type="radio" v-if="!multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
12
+ <input :disabled="!canChooseFile(file)" class="form-check-input" type="checkbox" v-if="multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
13
+ <input :disabled="!canChooseFile(file)" class="form-check-input" type="radio" v-if="!multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
14
14
  <label class="form-check-label" :for="'file-' + (file.fID || file.treeNodeID)">{{file.title}}</label>
15
15
  </div>
16
16
  </div>
@@ -38,8 +38,8 @@
38
38
  <tbody>
39
39
  <tr v-for="file in fileList" :key="(file.fID || file.treeNodeID) + 'list'" @click="onItemClick(file)">
40
40
  <td>
41
- <input type="checkbox" v-if="multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
42
- <input type="radio" v-if="!multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
41
+ <input type="checkbox" :disabled="!canChooseFile(file)" v-if="multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
42
+ <input type="radio" :disabled="!canChooseFile(file)" v-if="!multipleSelection && !file.isFolder" v-model="selectedFiles" :id="'file-' + file.fID" :value="file.fID">
43
43
  </td>
44
44
  <td class="ccm-image-chooser-icon"><span v-html="file.resultsThumbnailImg" width="32" height="32"></span></td>
45
45
  <td>{{file.fID}}</td>
@@ -100,6 +100,9 @@ export default {
100
100
  viewIsLoading: false
101
101
  }),
102
102
  props: {
103
+ filters: {
104
+ type: Array
105
+ },
103
106
  enableSort: {
104
107
  type: Boolean,
105
108
  required: false,
@@ -171,6 +174,37 @@ export default {
171
174
  }
172
175
  },
173
176
  methods: {
177
+ canChooseFile(file) {
178
+ var canChooseFile = -1
179
+ if (this.filters) {
180
+ var fileExtension = file.extension
181
+ var fileType = file.genericType
182
+ this.filters.forEach(function(filter) {
183
+ if (filter.filter === 'extension') {
184
+ if (filter.extensions.includes(fileExtension)) {
185
+ canChooseFile = true
186
+ } else {
187
+ canChooseFile = false
188
+ }
189
+ }
190
+ if (canChooseFile !== false) {
191
+ if (filter.filter === 'type') {
192
+ if (filter.type === fileType) {
193
+ canChooseFile = true
194
+ } else {
195
+ canChooseFile = false
196
+ }
197
+ }
198
+ }
199
+ })
200
+ }
201
+
202
+ if (canChooseFile === -1) {
203
+ return true
204
+ } else {
205
+ return canChooseFile
206
+ }
207
+ },
174
208
  getFiles() {
175
209
  const my = this
176
210
  my.rows = false
@@ -10,6 +10,7 @@
10
10
  :routePath="routePath + activeFolder"
11
11
  :enable-pagination="true"
12
12
  :enable-sort="true"
13
+ :filters="filters"
13
14
  :multipleSelection="multipleSelection"
14
15
  @folderClick="activeFolder = $event"/>
15
16
  </div>
@@ -51,6 +52,9 @@ export default {
51
52
  multipleSelection: {
52
53
  type: Boolean,
53
54
  default: true
55
+ },
56
+ filters: {
57
+ type: Array
54
58
  }
55
59
  },
56
60
  created() {
@@ -4,6 +4,7 @@
4
4
 
5
5
  <files :selectedFiles.sync="selectedFiles"
6
6
  :resultsFormFactor="formFactor"
7
+ :filters="filters"
7
8
  routePath="/ccm/system/file/chooser/recent"
8
9
  :multipleSelection="multipleSelection"/>
9
10
  </div>
@@ -37,6 +38,9 @@ export default {
37
38
  multipleSelection: {
38
39
  type: Boolean,
39
40
  default: true
41
+ },
42
+ filters: {
43
+ type: Array
40
44
  }
41
45
  },
42
46
  watch: {
@@ -13,19 +13,20 @@
13
13
  <select id="searchPresets" class="form-select search-presets-menu" v-model="activeSearchPreset">
14
14
  <option value="" selected>{{ i18n.selectPreset }}</option>
15
15
  <option v-for="searchPreset in searchPresets" :key="searchPreset.id" :value="searchPreset.id">
16
- {{searchPreset.presetName}}
16
+ {{ searchPreset.presetName }}
17
17
  </option>
18
18
  </select>
19
19
  </div>
20
20
  </div>
21
21
  <div class="mt-3" v-show="activeSearchPreset">
22
22
  <files v-if="activeSearchPreset"
23
- :selectedFiles.sync="selectedFiles"
24
- :resultsFormFactor="formFactor"
25
- :routePath="routePath + activeSearchPreset"
26
- :enable-pagination="true"
27
- :multipleSelection="multipleSelection"
28
- @folderClick="activeFolder = $event"/>
23
+ :selectedFiles.sync="selectedFiles"
24
+ :resultsFormFactor="formFactor"
25
+ :filters="filters"
26
+ :routePath="routePath + activeSearchPreset"
27
+ :enable-pagination="true"
28
+ :multipleSelection="multipleSelection"
29
+ @folderClick="activeFolder = $event"/>
29
30
  </div>
30
31
  </div>
31
32
  </template>
@@ -74,6 +75,9 @@ export default {
74
75
  multipleSelection: {
75
76
  type: Boolean,
76
77
  default: true
78
+ },
79
+ filters: {
80
+ type: Array
77
81
  }
78
82
  },
79
83
  methods: {
@@ -6,7 +6,8 @@
6
6
  <div class="col-md-4 ms-auto">
7
7
  <form @submit.prevent="search">
8
8
  <div class="ccm-header-search-form-input input-group">
9
- <input type="text" class="form-control border-end-0" :placeholder="i18n.search" autocomplete="false" v-model="searchText">
9
+ <input type="text" class="form-control border-end-0" :placeholder="i18n.search"
10
+ autocomplete="false" v-model="searchText">
10
11
  <button type="submit" class="input-group-icon">
11
12
  <svg width="16" height="16">
12
13
  <use xlink:href="#icon-search"/>
@@ -24,12 +25,13 @@
24
25
  </div>
25
26
  <div>
26
27
  <files v-if="keywords"
27
- :selectedFiles.sync="selectedFiles"
28
- :resultsFormFactor="formFactor"
29
- :routePath="routePath + keywords"
30
- :enable-pagination="true"
31
- :enable-sort="true"
32
- :multipleSelection="multipleSelection"/>
28
+ :selectedFiles.sync="selectedFiles"
29
+ :resultsFormFactor="formFactor"
30
+ :routePath="routePath + keywords"
31
+ :enable-pagination="true"
32
+ :enable-sort="true"
33
+ :filters="filters"
34
+ :multipleSelection="multipleSelection"/>
33
35
  </div>
34
36
  </div>
35
37
  </template>
@@ -71,10 +73,13 @@ export default {
71
73
  multipleSelection: {
72
74
  type: Boolean,
73
75
  default: true
76
+ },
77
+ filters: {
78
+ type: Array
74
79
  }
75
80
  },
76
81
  methods: {
77
- search () {
82
+ search() {
78
83
  this.keywords = this.searchText
79
84
  }
80
85
  },
@@ -34,6 +34,8 @@
34
34
  :selectedFiles.sync="selectedFiles"
35
35
  :resultsFormFactor.sync="resultsFormFactor"
36
36
  :filesReadyToUpload.sync="filesReadyToUpload"
37
+ :filters="filters"
38
+ @upload-complete="activateTabByKey('recent-uploads')"
37
39
  ref="c"
38
40
  />
39
41
  </transition>
@@ -125,6 +127,9 @@ export default {
125
127
  multipleSelection: {
126
128
  type: Boolean,
127
129
  default: true
130
+ },
131
+ filters: {
132
+ type: Array
128
133
  }
129
134
  },
130
135
  created() {
@@ -192,6 +197,19 @@ export default {
192
197
  isChooseFilesMode() {
193
198
  return this.activeNavItem.componentKey !== 'file-upload' && this.activeNavItem.componentKey !== 'external-file-provider'
194
199
  },
200
+ activateTabByKey(key) {
201
+ var my = this
202
+ this.choosers.forEach(function(chooser) {
203
+ if (chooser.id === key) {
204
+ my.activateTab(chooser)
205
+ }
206
+ })
207
+ this.uploaders.forEach(function(uploader) {
208
+ if (uploader.id === key) {
209
+ my.activateTab(uploader)
210
+ }
211
+ })
212
+ },
195
213
  activateTab(item) {
196
214
  this.activeNavItem = item
197
215
 
@@ -131,7 +131,8 @@ export default {
131
131
  me.uploadedFiles.forEach(function(file) {
132
132
  fileIds.push(file.fID)
133
133
  })
134
- ConcreteEvent.publish('FileManagerSelectFile', { fID: fileIds })
134
+ // Instead of firing this event let's use uploadComplete() below to re-select the Recent Uploads tab.
135
+ // ConcreteEvent.publish('FileManagerSelectFile', { fID: fileIds })
135
136
  me.uploadedFiles = []
136
137
  }
137
138
  me.uploadComplete()
@@ -222,7 +223,7 @@ export default {
222
223
  this.dropzone.removeAllFiles(true)
223
224
  },
224
225
  uploadComplete() {
225
- this.$emit('update:uploadCompleted')
226
+ this.$emit('upload-complete')
226
227
 
227
228
  ConcreteAlert.notify({
228
229
  title: 'Complete',
@@ -2,6 +2,7 @@
2
2
  <div>
3
3
  <upload-from-computer
4
4
  :upload-directory-id="uploadDirectoryId"
5
+ @upload-complete="$emit('upload-complete')"
5
6
  @uploadProgressStateChange="isUploadInProgress = $event"/>
6
7
 
7
8
  <concrete-file-directory-input
@@ -52,6 +52,9 @@ export default {
52
52
  },
53
53
  chooseText: {
54
54
  type: String
55
+ },
56
+ filters: {
57
+ type: Array
55
58
  }
56
59
  },
57
60
  watch: {
@@ -84,9 +87,13 @@ export default {
84
87
  },
85
88
  openChooser: function() {
86
89
  var my = this
90
+ var options = {}
91
+ if (my.filters) {
92
+ options.filters = my.filters
93
+ }
87
94
  ConcreteFileManager.launchDialog(function(r) {
88
95
  my.loadFile(r.fID)
89
- })
96
+ }, options)
90
97
  },
91
98
  loadFile(fileId) {
92
99
  var my = this
@@ -1,5 +1,5 @@
1
1
  <template>
2
- <div class="mb-3">
2
+ <div class="mb-3 ccm-context-theme">
3
3
  <select :name="inputName" data-select="theme-colors" data-width="100%">
4
4
  <option v-for="color in colorCollection.colors" :selected="selectedColor == color.variable" :data-content="dataContentAttribute(color)" :value="color.variable">{{ color.name }}</option>
5
5
  </select>
@@ -173,8 +173,8 @@ ConcreteLayout.prototype._setupFormEvents = function () {
173
173
  ConcreteLayout.prototype.buildThemeGridGrid = function () {
174
174
  this.$element.html('')
175
175
 
176
- var row = this.options.rowstart
177
- row += '<div id="ccm-theme-grid-edit-mode-row-wrapper">'
176
+ var row = '<div id="ccm-theme-grid-edit-mode-row-wrapper">'
177
+ row += this.options.rowstart
178
178
 
179
179
  var columnSpans = this._getThemeGridColumnSpan(this.columns)
180
180
  $.each(columnSpans, function (i, spanInfo) {
@@ -213,8 +213,8 @@ ConcreteLayout.prototype._updateThemeGridView = function (presetLoad) {
213
213
 
214
214
  ConcreteLayout.prototype._buildThemeGridGridFromPresetColumns = function (arLayoutColumns) {
215
215
  this.$element.html('')
216
- var row = this.options.rowstart
217
- row += '<div id="ccm-theme-grid-edit-mode-row-wrapper">'
216
+ var row = '<div id="ccm-theme-grid-edit-mode-row-wrapper">'
217
+ row += this.options.rowstart
218
218
  $.each(arLayoutColumns, function (i, column) {
219
219
  var columnHTML = '<div id="ccm-edit-layout-column-' + i + '" class="ccm-theme-grid-column" ' +
220
220
  'data-offset="' + column.arLayoutColumnOffset + '" data-span="' + column.arLayoutColumnSpan + '"><div class="ccm-layout-column-highlight">' +
@@ -17,14 +17,7 @@ class ConcreteFileManager {
17
17
  }
18
18
 
19
19
  if (options.filters.length > 0) {
20
- data['field[]'] = []
21
-
22
- for (i = 0; i < options.filters.length; i++) {
23
- var filter = $.extend(true, {}, options.filters[i]) // clone
24
- data['field[]'].push(filter.field)
25
- delete (filter.field)
26
- $.extend(data, filter) // add all remaining fields to the data
27
- }
20
+ data.filters = options.filters
28
21
  }
29
22
 
30
23
  $.fn.dialog.open({
@@ -201,6 +201,7 @@ div#ccm-toolbar {
201
201
  li.ccm-toolbar-page-edit-mode-active {
202
202
  > a {
203
203
  background-color: $green;
204
+ color: #fff;
204
205
 
205
206
  svg {
206
207
  fill: white;
@@ -20,35 +20,6 @@
20
20
  }
21
21
 
22
22
 
23
- // Root
24
- //
25
- // Ability to the value of the root font sizes, affecting the value of `rem`.
26
- // null by default, thus nothing is generated.
27
-
28
- :root {
29
- font-size: $font-size-root;
30
-
31
- @if $enable-smooth-scroll {
32
- @media (prefers-reduced-motion: no-preference) {
33
- scroll-behavior: smooth;
34
- }
35
- }
36
- }
37
-
38
-
39
- // Body
40
- //
41
- // 1. Remove the margin in all browsers.
42
- // 2. As a best practice, apply a default `background-color`.
43
- // 3. Prevent adjustments of font size after orientation changes in iOS.
44
- // 4. Change the default tap highlight to be completely transparent in iOS.
45
-
46
- html.ccm-toolbar-visible {
47
- // We _could_ set this by setting font-size-root, but we don't really want to screw with the theme loading this
48
- // unless we know the toolbar is visible.
49
- font-size: 16px; // By setting this here, rem declarations in BS5 work off of 16px, and the base theme can do whatever it wants at body
50
- }
51
-
52
23
  .ccm-ui {
53
24
  margin: 0; // 1
54
25
  font-family: $font-family-base;
@@ -12,6 +12,13 @@ div.ccm-block-hero-image {
12
12
  width: 100%;
13
13
  }
14
14
 
15
+ div.ccm-block-hero-image-text {
16
+ align-items: center;
17
+ display: flex;
18
+ flex-direction: column;
19
+ justify-content: center;
20
+ }
21
+
15
22
  div.ccm-block-hero-image-cover {
16
23
  z-index: 2;
17
24
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@concretecms/bedrock",
3
- "version": "1.1.0",
3
+ "version": "1.1.4",
4
4
  "description": "The asset framework and dependencies for Concrete CMS.",
5
5
  "scripts": {
6
6
  "lint": "standardx \"**/*.{js,vue}\" && stylelint assets/**/*.{scss,vue}",
@@ -21,7 +21,7 @@
21
21
  "bootstrap": "^5.0.1",
22
22
  "bootstrap-select": "^1.14.0-beta2",
23
23
  "bootstrap-tourist": "git+https://git@github.com/concrete5/bootstrap-tourist.git",
24
- "ckeditor4": "^4.16.2",
24
+ "ckeditor4": "^4.17.1",
25
25
  "ckeditor4-vue": "^1.3.2",
26
26
  "dropzone": "^5.7.2",
27
27
  "fullcalendar": "^3.10.2",