jobdone-shared-files 1.0.13 → 1.0.16

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 (32) hide show
  1. package/ProjectManagement/projectNavbar.vue +363 -363
  2. package/autocompleteSelect.vue +461 -461
  3. package/common/directives/collapse.js +12 -12
  4. package/common/directives/popovers.js +10 -10
  5. package/common/directives/selectPlaceholder.js +52 -52
  6. package/common/directives/textareaAutoHeight.js +10 -10
  7. package/common/directives/tooltip.js +10 -10
  8. package/common/format.js +26 -26
  9. package/index.js +14 -14
  10. package/lightboxWithOverview.vue +156 -156
  11. package/package.json +19 -19
  12. package/paginate.vue +141 -141
  13. package/style/css/vue-loading-overlay/index.css +40 -40
  14. package/style/scss/Common/Animation.scss +9 -9
  15. package/style/scss/Common/SelectableTable.scss +34 -34
  16. package/style/scss/Common/filepond.scss +31 -31
  17. package/style/scss/Common/thumbnail-group.scss +14 -14
  18. package/style/scss/Layout/LayoutBase.scss +1031 -1031
  19. package/style/scss/Layout/LayoutMobile.scss +206 -206
  20. package/style/scss/Layout/LayoutProject.scss +126 -126
  21. package/style/scss/Layout/LayoutSinglePage.scss +17 -17
  22. package/style/scss/Layout/LayoutTwoColumn.scss +60 -60
  23. package/style/scss/Settings/_Mixins.scss +232 -232
  24. package/style/scss/Settings/_MobileVariables.scss +11 -11
  25. package/style/scss/Settings/_bs-variables-dark.scss +70 -70
  26. package/style/scss/Settings/_bs-variables.scss +1743 -1743
  27. package/style/scss/Settings/_color-mode.scss +122 -122
  28. package/style/scss/Settings/_custom-variables.scss +10 -10
  29. package/tagEditor.vue +249 -249
  30. package/tree.vue +68 -69
  31. package/treeItem.vue +355 -371
  32. package/vueLoadingOverlay.vue +74 -74
package/treeItem.vue CHANGED
@@ -1,372 +1,356 @@
1
- <template>
2
- <li class="tree-item" :class="[itemClass]">
3
- <div class="card flex-row d-flex input-group flex-nowrap">
4
- <button type="button" class="btn text-primary border-end px-1" :disabled="!item.children" data-bs-toggle="collapse" :data-bs-target="'#collapse-'+item.id">
5
- <span class="material-icons">arrow_drop_down</span>
6
- </button>
7
- <input type="radio" name="tree-item" :id="item.id">
8
- <label class="btn-title d-flex text-start rounded-0 flex-grow-1"
9
- :for="item.id" @click="clickItem(item)">
10
- <div class="btn btn-text border-start">{{item.title}}</div>
11
- <slot name="icon">
12
- <div class="btn d-flex align-items-center border-start rounded-0 text-primary h-100 ms-auto">
13
- <span class="material-icons icon-18"></span>
14
- </div>
15
- </slot>
16
- </label>
17
- </div>
18
- <template v-if="item.children">
19
- <ul :id="'collapse-'+item.id" class="content-children show" v-collapse>
20
- <TreeItem class="children-box" v-for="(subItem, subIndex) in item.children"
21
- :key="subItem.id"
22
- :item="subItem"
23
- :index="subIndex"
24
- :click-item="clickItem"
25
- :active-id="activeId"
26
- :tree-item-class="treeItemClass">
27
- <template v-slot:icon>
28
- <slot name="icon">
29
- <div class="btn d-flex align-items-center border-start rounded-0 text-primary h-100 ms-auto">
30
- <span class="material-icons icon-18"></span>
31
- </div>
32
- </slot>
33
- </template>
34
- </TreeItem>
35
- </ul>
36
- </template>
37
- </li>
38
- </template>
39
-
40
- <script>
41
- import { ref, computed } from 'vue';
42
- import collapse from './common/directives/collapse';
43
- export default {
44
- name: 'TreeItem',
45
- props: {
46
- item: {
47
- type: Object,
48
- required: true
49
- },
50
- index: {
51
- type: Number,
52
- required: true
53
- },
54
- clickItem: {
55
- type: Function
56
- },
57
- activeId: {
58
- type: String,
59
- required: true
60
- },
61
- treeItemClass: {
62
- type: Array,
63
- default: function () {
64
- return [];
65
- }
66
- }
67
- },
68
- directives: {
69
- collapse
70
- },
71
- setup(props, { emit }) {
72
- const itemClass = computed(() => {
73
- var classList = [...props.treeItemClass];
74
- if (props.activeId === props.item.id) {
75
- classList.push('active');
76
- }
77
- return classList;
78
- });
79
- return {
80
- itemClass: itemClass
81
- };
82
- }
83
- }
84
- </script>
85
-
86
- <style scoped lang="scss">
87
- @import "../bootstrap/scss/functions";
88
- @import "./style/scss/Settings/bs-variables";
89
- @import "../bootstrap/scss/mixins";
90
- @import "./style/scss/Settings/Mixins";
91
-
92
- li {
93
- list-style-type: none;
94
- }
95
-
96
- // 基本 sizes
97
- .tree-item {
98
- .btn {
99
- --bs-btn-padding-x: 0.75em;
100
- --bs-btn-padding-y: 0.375em;
101
- --bs-btn-font-size: 1em;
102
- }
103
-
104
- .card {
105
- --bs-card-spacer-y: 1em;
106
- --bs-card-spacer-x: 1em;
107
- --bs-card-title-spacer-y: 0.5em;
108
- --bs-card-cap-padding-y: 0.5em;
109
- --bs-card-cap-padding-x: 1em;
110
- --bs-card-img-overlay-padding: 1em;
111
- --bs-card-group-margin: 0.75em;
112
- }
113
-
114
- .material-icons {
115
- font-size: 1.5em;
116
-
117
- &.icon-14 {
118
- font-size: 0.875em;
119
- }
120
-
121
- &.icon-18 {
122
- font-size: 1.125em;
123
- }
124
-
125
- &.icon-28 {
126
- font-size: 1.75em;
127
- }
128
-
129
- &.icon-32 {
130
- font-size: 2em;
131
- }
132
- }
133
- }
134
-
135
- // hover效果與優化
136
- // firefox 暫不支援 has
137
- .tree-item:has([data-bs-toggle="collapse"]:hover) + .collapse {
138
- will-change: height;
139
- }
140
-
141
- .tree-item:hover > .card,
142
- .tree-item .card:focus-within {
143
- background-color: lighten( $primary, 32% );
144
- border-color: rgba( $primary, .4 );
145
- }
146
-
147
- // active效果
148
- .tree-item.active {
149
- > .card {
150
- background-color: lighten( $primary, 30% );
151
- border-color: rgba( $primary, .5 );
152
- }
153
-
154
- .btn-title {
155
- color: $primary;
156
- }
157
- }
158
-
159
- .btn-title {
160
- .btn {
161
- border-radius: 0;
162
-
163
- &:focus, &:active {
164
- border-color: transparent;
165
- }
166
- }
167
-
168
- .btn-text {
169
- width: 100%;
170
- text-align: left;
171
- overflow-wrap: anywhere;
172
- }
173
- }
174
-
175
- label.btn-title {
176
- cursor: pointer;
177
- }
178
-
179
- // 隱藏 input
180
- .tree-item {
181
- position: relative;
182
-
183
- input[type="checkbox"], input[type="radio"] {
184
- position: absolute;
185
- @include size(0);
186
- opacity: 0;
187
- pointer-events: none;
188
-
189
- ~ .btn-title .material-icons:before {
190
- content: "\e836";
191
- display: inline-block;
192
- font-family: inherit;
193
- }
194
-
195
- &:checked ~ .btn-title .material-icons:before {
196
- content: "\e837";
197
- }
198
- }
199
- }
200
-
201
-
202
- // 刪除子層標示 UI
203
- .tree-item:has(.btn.text-danger:hover) {
204
- .card {
205
- background-color: lighten( $danger, 43% );
206
- border-color: rgba( $danger, .5 );
207
-
208
- .btn {
209
- color: $danger;
210
- }
211
- }
212
- }
213
- // 刪除子層標示 UI (含子層)
214
- // .tree-child:has(.btn.text-danger:hover){
215
- // .card, + .content-children .card{
216
- // background-color: lighten( $danger, 43% );
217
- // border-color: rgba( $danger, .5 );
218
- // .btn{
219
- // color: $danger;
220
- // }
221
- // }
222
- // }
223
-
224
- .btn-no-children {
225
- cursor: auto;
226
-
227
- &:focus {
228
- border-color: transparent;
229
- }
230
- }
231
-
232
- // 基本 style
233
- $card-margin: .2em;
234
- $line-padding: .7em;
235
-
236
- .tree-item {
237
- display: flex;
238
- flex-direction: column;
239
- width: 100%;
240
- margin-top: $card-margin;
241
-
242
- .card {
243
- position: relative;
244
- flex-grow: 1;
245
- transition: $transition-base;
246
- z-index: 2;
247
- }
248
- }
249
-
250
- .col-action {
251
- @include flex-center;
252
- width: 2.8rem;
253
- }
254
-
255
-
256
- // 開合 style
257
- .btn[data-bs-toggle="collapse"] {
258
- .material-icons {
259
- transition: $transition-base;
260
- }
261
-
262
- &[aria-expanded="false"] .material-icons {
263
- transform: rotate(-90deg);
264
- }
265
-
266
- &:disabled, &.disabled {
267
- border-color: transparent;
268
- }
269
- }
270
-
271
- // 畫線 style
272
- .content-children {
273
- padding-left: 1.5rem;
274
- --tree-border-color: #fff;
275
- position: relative;
276
-
277
- &:before {
278
- content: "";
279
- position: absolute;
280
- display: block;
281
- left: -$line-padding;
282
- bottom: 24px;
283
- width: 1px;
284
- height: 100%;
285
- z-index: 1;
286
- background-color: var(--tree-border-color);
287
- }
288
- // // line color
289
- &:before, .tree-item .card:before, .tree-item .card:after {
290
- background-color: var(--tree-border-color);
291
- }
292
- }
293
-
294
- .tree-item {
295
- &:last-child > .content-children:before {
296
- display: none;
297
- }
298
-
299
- .card {
300
- position: relative;
301
-
302
- &:before, &:after {
303
- content: "";
304
- position: absolute;
305
- left: calc(-#{$line-padding} - #{$border-width});
306
- z-index: 1;
307
- }
308
-
309
- &:before {
310
- bottom: 50%;
311
- width: 1px;
312
- height: calc(100% + #{$card-margin}*2 + #{$border-width}*2);
313
- }
314
-
315
- &:after {
316
- top: 0;
317
- bottom: 0;
318
- width: $line-padding;
319
- height: 1px;
320
- margin: auto;
321
- }
322
- }
323
-
324
- &:nth-child(1) > .card:before {
325
- height: calc(50% + #{$card-margin} + #{$border-width});
326
- }
327
- }
328
-
329
-
330
- // 小版本
331
- .tree-item-sm {
332
- > .card {
333
- font-size: 86%;
334
- }
335
-
336
- .content-children {
337
- padding-left: 1rem;
338
- }
339
-
340
- .content-children:before {
341
- left: -10px;
342
- bottom: 19px;
343
- }
344
- }
345
- // .tree-item-sm + .content-children{
346
- // > .children-box{
347
- // padding-left: 1rem;
348
- // }
349
- // }
350
-
351
-
352
- // 白背景版本
353
- .tree-item-in-white {
354
- .content-children {
355
- --tree-border-color: var(--bs-border-color);
356
- }
357
-
358
- .card {
359
- --bs-card-bg: var(--gray-100);
360
- --bs-card-border-color: var(--bs-border-color);
361
- }
362
-
363
- &:hover > .card,
364
- .card:focus-within {
365
- background-color: $white;
366
- }
367
- // active效果
368
- &.active .card {
369
- background-color: $white;
370
- }
371
- }
1
+ <template>
2
+ <li class="tree-item" :class="[itemClass]">
3
+ <div class="card flex-row d-flex input-group flex-nowrap">
4
+ <button type="button" class="btn text-primary border-end px-1" :disabled="!item.children" data-bs-toggle="collapse" :data-bs-target="'#collapse-'+item.id">
5
+ <span class="material-icons">arrow_drop_down</span>
6
+ </button>
7
+ <div class="btn-title d-flex text-start rounded-0 flex-grow-1"
8
+ :for="item.id" @click="clickItem(item)">
9
+ <div class="btn btn-text border-start">{{item.title}}</div>
10
+ <slot name="icon">
11
+ <div class="btn d-flex align-items-center border-start rounded-0 text-primary h-100 ms-auto">
12
+ <span class="material-icons icon-18"></span>
13
+ </div>
14
+ </slot>
15
+ </div>
16
+ </div>
17
+ <template v-if="item.children">
18
+ <ul :id="'collapse-'+item.id" class="content-children show" v-collapse>
19
+ <TreeItem class="children-box" v-for="(subItem, subIndex) in item.children"
20
+ :key="subItem.id"
21
+ :item="subItem"
22
+ :index="subIndex"
23
+ :click-item="clickItem"
24
+ :active-id="activeId"
25
+ :tree-item-class="treeItemClass">
26
+ <template v-slot:icon>
27
+ <slot name="icon">
28
+ <div class="btn d-flex align-items-center border-start rounded-0 text-primary h-100 ms-auto">
29
+ <span class="material-icons icon-18"></span>
30
+ </div>
31
+ </slot>
32
+ </template>
33
+ </TreeItem>
34
+ </ul>
35
+ </template>
36
+ </li>
37
+ </template>
38
+
39
+ <script>
40
+ import { ref, computed } from 'vue';
41
+ import collapse from './common/directives/collapse';
42
+ export default {
43
+ name: 'TreeItem',
44
+ props: {
45
+ item: {
46
+ type: Object,
47
+ required: true
48
+ },
49
+ index: {
50
+ type: Number,
51
+ required: true
52
+ },
53
+ clickItem: {
54
+ type: Function
55
+ },
56
+ activeId: {
57
+ type: String,
58
+ required: true
59
+ },
60
+ treeItemClass: {
61
+ type: Array,
62
+ default: function () {
63
+ return [];
64
+ }
65
+ }
66
+ },
67
+ directives: {
68
+ collapse
69
+ },
70
+ setup(props, { emit }) {
71
+ const itemClass = computed(() => {
72
+ var classList = [...props.treeItemClass];
73
+ if (props.activeId === props.item.id) {
74
+ classList.push('active');
75
+ }
76
+ return classList;
77
+ });
78
+ return {
79
+ itemClass: itemClass
80
+ };
81
+ }
82
+ }
83
+ </script>
84
+
85
+ <style scoped lang="scss">
86
+ @import "../bootstrap/scss/functions";
87
+ @import "./style/scss/Settings/bs-variables";
88
+ @import "../bootstrap/scss/mixins";
89
+ @import "./style/scss/Settings/Mixins";
90
+
91
+ li {
92
+ list-style-type: none;
93
+ }
94
+
95
+ // 基本 sizes
96
+ .tree-item {
97
+ .btn {
98
+ --bs-btn-padding-x: 0.75em;
99
+ --bs-btn-padding-y: 0.375em;
100
+ --bs-btn-font-size: 1em;
101
+ }
102
+
103
+ .card {
104
+ --bs-card-spacer-y: 1em;
105
+ --bs-card-spacer-x: 1em;
106
+ --bs-card-title-spacer-y: 0.5em;
107
+ --bs-card-cap-padding-y: 0.5em;
108
+ --bs-card-cap-padding-x: 1em;
109
+ --bs-card-img-overlay-padding: 1em;
110
+ --bs-card-group-margin: 0.75em;
111
+ }
112
+
113
+ .material-icons {
114
+ font-size: 1.5em;
115
+
116
+ &.icon-14 {
117
+ font-size: 0.875em;
118
+ }
119
+
120
+ &.icon-18 {
121
+ font-size: 1.125em;
122
+ }
123
+
124
+ &.icon-28 {
125
+ font-size: 1.75em;
126
+ }
127
+
128
+ &.icon-32 {
129
+ font-size: 2em;
130
+ }
131
+ }
132
+ }
133
+
134
+ // hover效果與優化
135
+ // firefox 暫不支援 has
136
+ .tree-item:has([data-bs-toggle="collapse"]:hover) + .collapse {
137
+ will-change: height;
138
+ }
139
+
140
+ .tree-item:hover > .card,
141
+ .tree-item .card:focus-within {
142
+ background-color: lighten( $primary, 32% );
143
+ border-color: rgba( $primary, .4 );
144
+ }
145
+
146
+ .tree-item{
147
+ .btn-title .material-icons:before {
148
+ content: "\e836";
149
+ display: inline-block;
150
+ font-family: inherit;
151
+ }
152
+
153
+ // active效果
154
+ &.active {
155
+ > .card {
156
+ background-color: lighten( $primary, 30% );
157
+ border-color: rgba( $primary, .5 );
158
+ }
159
+ > .card .btn-title .material-icons:before {
160
+ content: "\e837";
161
+ }
162
+ .btn-title {
163
+ color: $primary;
164
+ }
165
+ }
166
+ }
167
+
168
+ .btn-title {
169
+ cursor: pointer;
170
+ .btn {
171
+ border-radius: 0;
172
+
173
+ &:focus, &:active {
174
+ border-color: transparent;
175
+ }
176
+ }
177
+
178
+ .btn-text {
179
+ width: 100%;
180
+ text-align: left;
181
+ overflow-wrap: anywhere;
182
+ }
183
+ }
184
+
185
+
186
+ // 刪除子層標示 UI
187
+ .tree-item:has(.btn.text-danger:hover) {
188
+ .card {
189
+ background-color: lighten( $danger, 43% );
190
+ border-color: rgba( $danger, .5 );
191
+
192
+ .btn {
193
+ color: $danger;
194
+ }
195
+ }
196
+ }
197
+ // 刪除子層標示 UI (含子層)
198
+ // .tree-child:has(.btn.text-danger:hover){
199
+ // .card, + .content-children .card{
200
+ // background-color: lighten( $danger, 43% );
201
+ // border-color: rgba( $danger, .5 );
202
+ // .btn{
203
+ // color: $danger;
204
+ // }
205
+ // }
206
+ // }
207
+
208
+ .btn-no-children {
209
+ cursor: auto;
210
+
211
+ &:focus {
212
+ border-color: transparent;
213
+ }
214
+ }
215
+
216
+ // 基本 style
217
+ $card-margin: .2em;
218
+ $line-padding: .7em;
219
+
220
+ .tree-item {
221
+ display: flex;
222
+ flex-direction: column;
223
+ width: 100%;
224
+ margin-top: $card-margin;
225
+
226
+ .card {
227
+ position: relative;
228
+ flex-grow: 1;
229
+ transition: $transition-base;
230
+ z-index: 2;
231
+ }
232
+ }
233
+
234
+ .col-action {
235
+ @include flex-center;
236
+ width: 2.8rem;
237
+ }
238
+
239
+
240
+ // 開合 style
241
+ .btn[data-bs-toggle="collapse"] {
242
+ .material-icons {
243
+ transition: $transition-base;
244
+ }
245
+
246
+ &[aria-expanded="false"] .material-icons {
247
+ transform: rotate(-90deg);
248
+ }
249
+
250
+ &:disabled, &.disabled {
251
+ border-color: transparent;
252
+ }
253
+ }
254
+
255
+ // 畫線 style
256
+ .content-children {
257
+ padding-left: 1.5rem;
258
+ --tree-border-color: #fff;
259
+ position: relative;
260
+
261
+ &:before {
262
+ content: "";
263
+ position: absolute;
264
+ display: block;
265
+ left: -$line-padding;
266
+ bottom: 24px;
267
+ width: 1px;
268
+ height: 100%;
269
+ z-index: 1;
270
+ background-color: var(--tree-border-color);
271
+ }
272
+ // // line color
273
+ &:before, .tree-item .card:before, .tree-item .card:after {
274
+ background-color: var(--tree-border-color);
275
+ }
276
+ }
277
+
278
+ .tree-item {
279
+ &:last-child > .content-children:before {
280
+ display: none;
281
+ }
282
+
283
+ .card {
284
+ position: relative;
285
+
286
+ &:before, &:after {
287
+ content: "";
288
+ position: absolute;
289
+ left: calc(-#{$line-padding} - #{$border-width});
290
+ z-index: 1;
291
+ }
292
+
293
+ &:before {
294
+ bottom: 50%;
295
+ width: 1px;
296
+ height: calc(100% + #{$card-margin}*2 + #{$border-width}*2);
297
+ }
298
+
299
+ &:after {
300
+ top: 0;
301
+ bottom: 0;
302
+ width: $line-padding;
303
+ height: 1px;
304
+ margin: auto;
305
+ }
306
+ }
307
+
308
+ &:nth-child(1) > .card:before {
309
+ height: calc(50% + #{$card-margin} + #{$border-width});
310
+ }
311
+ }
312
+
313
+
314
+ // 小版本
315
+ .tree-item-sm {
316
+ > .card {
317
+ font-size: 86%;
318
+ }
319
+
320
+ .content-children {
321
+ padding-left: 1rem;
322
+ }
323
+
324
+ .content-children:before {
325
+ left: -10px;
326
+ bottom: 19px;
327
+ }
328
+ }
329
+ // .tree-item-sm + .content-children{
330
+ // > .children-box{
331
+ // padding-left: 1rem;
332
+ // }
333
+ // }
334
+
335
+
336
+ // 白背景版本
337
+ .tree-item-in-white {
338
+ .content-children {
339
+ --tree-border-color: var(--bs-border-color);
340
+ }
341
+
342
+ .card {
343
+ --bs-card-bg: var(--gray-100);
344
+ --bs-card-border-color: var(--bs-border-color);
345
+ }
346
+
347
+ &:hover > .card,
348
+ .card:focus-within {
349
+ background-color: $white;
350
+ }
351
+ // active效果
352
+ &.active .card {
353
+ background-color: $white;
354
+ }
355
+ }
372
356
  </style>