@everchron/ec-shards 0.7.11 → 0.7.14

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@everchron/ec-shards",
3
- "version": "0.7.11",
3
+ "version": "0.7.14",
4
4
  "private": false,
5
5
  "description": "Everchron Shards UI Library",
6
6
  "repository": "https://github.com/everchron/ec-shards.git",
@@ -0,0 +1,9 @@
1
+ <svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path vector-effect="non-scaling-stroke" d="M11.3467 15.6289L13.7833 18.0655L19.1022 12.7455" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
3
+ <path vector-effect="non-scaling-stroke" d="M12.5 25H7.22222C5.99444 25 5 24.0056 5 22.7778V7.22222C5 5.99444 5.99444 5 7.22222 5H22.7778C24.0056 5 25 5.99444 25 7.22222V15" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
4
+ <path vector-effect="non-scaling-stroke" d="M21 25.4999C20.5088 25.4999 20.0171 25.4109 19.5393 25.2524" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
5
+ <path vector-effect="non-scaling-stroke" d="M26.1812 22.234C25.0775 23.9835 23.0387 25.5 21 25.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
6
+ <path vector-effect="non-scaling-stroke" d="M25.1294 20.4605C25.5325 20.865 25.8907 21.306 26.1812 21.7665C26.2728 21.912 26.2728 22.0885 26.1812 22.234" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
7
+ <path vector-effect="non-scaling-stroke" d="M23.0954 19C22.4235 18.6849 21.7116 18.5001 21 18.5001C18.9613 18.5001 16.9225 20.0166 15.8188 21.7666C15.7273 21.9121 15.7273 22.0886 15.8188 22.2341C16.2233 22.8751 16.7532 23.4847 17.3625 24" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
8
+ <path vector-effect="non-scaling-stroke" d="M16.5 25.5L25 18" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
9
+ </svg>
@@ -0,0 +1,8 @@
1
+ <svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path vector-effect="non-scaling-stroke" d="M12.5 25H7.22222C5.99444 25 5 24.0056 5 22.7778V7.22222C5 5.99444 5.99444 5 7.22222 5H22.7778C24.0056 5 25 5.99444 25 7.22222V15" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
3
+ <path vector-effect="non-scaling-stroke" d="M21 25.4999C20.5088 25.4999 20.0171 25.4109 19.5393 25.2524" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
4
+ <path vector-effect="non-scaling-stroke" d="M26.1812 22.234C25.0775 23.9835 23.0387 25.5 21 25.5" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
5
+ <path vector-effect="non-scaling-stroke" d="M25.1294 20.4605C25.5325 20.865 25.8907 21.306 26.1812 21.7665C26.2728 21.912 26.2728 22.0885 26.1812 22.234" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
6
+ <path vector-effect="non-scaling-stroke" d="M23.0954 19C22.4235 18.6849 21.7116 18.5001 21 18.5001C18.9613 18.5001 16.9225 20.0166 15.8188 21.7666C15.7273 21.9121 15.7273 22.0886 15.8188 22.2341C16.2233 22.8751 16.7532 23.4847 17.3625 24" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
7
+ <path vector-effect="non-scaling-stroke" d="M16.5 25.5L25 18" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
8
+ </svg>
@@ -0,0 +1,6 @@
1
+ <svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path vector-effect="non-scaling-stroke" d="M10.9 6L7 9.9L10.9 13.8" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
3
+ <path vector-effect="non-scaling-stroke" d="M22.1667 9.89996H7" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
4
+ <path vector-effect="non-scaling-stroke" d="M18.2667 24.6333L22.1667 20.7333L18.2667 16.8333" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
5
+ <path vector-effect="non-scaling-stroke" d="M7 20.7333H22.1667" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
6
+ </svg>
@@ -0,0 +1,5 @@
1
+ <svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <path vector-effect="non-scaling-stroke" d="M17.0312 6.27644L25.3284 20.7974C26.2926 22.4853 25.0738 24.5859 23.1303 24.5859H6.53583C4.59124 24.5859 3.37249 22.4853 4.33774 20.7974L12.635 6.27644C13.6067 4.57452 16.0594 4.57452 17.0312 6.27644Z" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
3
+ <path vector-effect="non-scaling-stroke" d="M17 15L13 19" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
4
+ <path vector-effect="non-scaling-stroke" d="M13 15L17 19" stroke="currentColor" stroke-linecap="round" stroke-linejoin="round"/>
5
+ </svg>
@@ -7,6 +7,7 @@
7
7
  subtle ? 'subtle' : '',
8
8
  pale ? 'pale' : '',
9
9
  unreactive ? 'unreactive' : '',
10
+ loading ? 'loading' : '',
10
11
  sizeClass
11
12
  ]"
12
13
  :disabled="disabled"
@@ -14,7 +15,7 @@
14
15
  @mouseover="$emit('mouseover', $event)"
15
16
  @mouseleave="$emit('mouseleave', $event)">
16
17
 
17
- <ecs-icon v-if="icon" :type="icon" :width="iconSize" :height="iconSize" />
18
+ <ecs-icon v-if="icon || loading" :type="iconType" :width="iconSize" :height="iconSize" />
18
19
  <div v-if="label != null" class="button-label">{{ label }}</div>
19
20
  <div v-if="chevron" class="chevron" :class="active ? 'expand' : ''" />
20
21
  </button>
@@ -60,6 +61,10 @@
60
61
  unreactive: {
61
62
  type: Boolean,
62
63
  default: false
64
+ },
65
+ loading: {
66
+ type: Boolean,
67
+ default: false
63
68
  }
64
69
  },
65
70
 
@@ -81,6 +86,13 @@
81
86
  return '16'
82
87
  else
83
88
  return '20'
89
+ },
90
+
91
+ iconType() {
92
+ if (this.loading)
93
+ return `loading`
94
+ else
95
+ return this.icon
84
96
  }
85
97
  }
86
98
  }
@@ -183,14 +195,6 @@
183
195
  }
184
196
  }
185
197
 
186
- &.active{
187
- background: rgba($blue-8, .05);
188
-
189
- .icon{
190
- color: $blue-8;
191
- }
192
- }
193
-
194
198
  &.pale{
195
199
  color: $gray-10;
196
200
  background: rgba($gray-7, .08);
@@ -218,10 +222,31 @@
218
222
  }
219
223
  }
220
224
 
225
+ &.active{
226
+ background: rgba($blue-8, .05);
227
+
228
+ .icon{
229
+ color: $blue-8;
230
+ }
231
+ }
232
+
221
233
  &.unreactive{
222
234
  cursor: default;
223
235
  }
224
236
 
237
+ &.loading{
238
+ opacity: .7;
239
+ cursor: wait;
240
+
241
+ .icon{
242
+ animation: spin .8s infinite linear reverse;
243
+ }
244
+
245
+ &:after{
246
+ opacity: 0;
247
+ }
248
+ }
249
+
225
250
  &:disabled{
226
251
  opacity: .5;
227
252
  cursor: default;
@@ -3,30 +3,32 @@
3
3
  :class="[
4
4
  iconClass,
5
5
  active ? 'active' : '',
6
+ loading ? 'loading' : '',
6
7
  activeHighlight ? 'active-highlight' : '',
7
8
  dropdown ? 'ecs-toolbar-button-dropdown' : '',
8
9
  dropdownClass]"
9
10
  @click="$emit('click', $event)">
10
11
 
11
- <ecs-icon v-if="icon && iconPosition == 'left'" :width="iconSize" :height="iconSize" :color="iconTint" :type="icon" />
12
+ <ecs-icon v-if="(icon && iconPosition == 'left') || (loading && iconPosition == 'left')" :width="iconSize" :height="iconSize" :color="iconTint" :type="iconType" :spinning="loading" />
12
13
  <slot></slot>
13
14
  <span class="badge" v-if="badge" :style="{ background: badgeColor }"></span>
14
- <ecs-icon v-if="icon && iconPosition == 'right'" :width="iconSize" :height="iconSize" :color="iconTint" :type="icon" />
15
+ <ecs-icon v-if="(icon && iconPosition == 'right') || (loading && iconPosition == 'right')" :width="iconSize" :height="iconSize" :color="iconTint" :type="iconType" :spinning="loading" />
15
16
  </a>
16
17
 
17
18
  <button v-else class="ecs-toolbar-button"
18
19
  :class="[
19
20
  iconClass,
20
21
  active ? 'active' : '',
22
+ loading ? 'loading' : '',
21
23
  activeHighlight ? 'active-highlight' : '',
22
24
  dropdown ? 'ecs-toolbar-button-dropdown' : '',
23
25
  dropdownClass]"
24
26
  @click="$emit('click', $event)">
25
27
 
26
- <ecs-icon v-if="icon && iconPosition == 'left'" :width="iconSize" :height="iconSize" :color="iconTint" :type="icon" />
28
+ <ecs-icon v-if="(icon && iconPosition == 'left') || (loading && iconPosition == 'left')" :width="iconSize" :height="iconSize" :color="iconTint" :type="iconType" :spinning="loading" />
27
29
  <slot></slot>
28
30
  <span class="badge" v-if="badge" :style="{ background: badgeColor }"></span>
29
- <ecs-icon v-if="icon && iconPosition == 'right'" :width="iconSize" :height="iconSize" :color="iconTint" :type="icon" />
31
+ <ecs-icon v-if="(icon && iconPosition == 'right') || (loading && iconPosition == 'right')" :width="iconSize" :height="iconSize" :color="iconTint" :type="iconType" :spinning="loading" />
30
32
  </button>
31
33
  </template>
32
34
 
@@ -51,6 +53,10 @@
51
53
  type: String,
52
54
  default: null
53
55
  },
56
+ loading: {
57
+ type: Boolean,
58
+ default: false
59
+ },
54
60
  iconSize: {
55
61
  type: String,
56
62
  default: '26'
@@ -99,6 +105,12 @@
99
105
  return this.icon
100
106
  },
101
107
 
108
+ iconType() {
109
+ if (this.loading)
110
+ return 'loading'
111
+ return this.icon
112
+ },
113
+
102
114
  iconTint() {
103
115
  if (this.activeHighlight)
104
116
  return '#0961EB'
@@ -197,6 +209,11 @@
197
209
  }
198
210
  }
199
211
 
212
+ &.loading{
213
+ cursor: wait;
214
+ opacity: .7;
215
+ }
216
+
200
217
  &-dropdown{
201
218
  padding-right: 22px;
202
219
 
@@ -5,6 +5,7 @@
5
5
  $slots.actions ? 'ecs-data-card-hover' : '',
6
6
  hover ? 'ecs-data-card-hover' : '',
7
7
  active ? 'active' : '',
8
+ shadow ? 'shadow' : '',
8
9
  isExpanded ? 'expanded' : '',
9
10
  loading ? 'loading' : ''
10
11
  ]">
@@ -65,6 +66,10 @@
65
66
  type: Boolean,
66
67
  default: false
67
68
  },
69
+ shadow: {
70
+ type: Boolean,
71
+ default: false
72
+ },
68
73
  control: {
69
74
  type: Boolean,
70
75
  default: false
@@ -171,6 +176,12 @@
171
176
  }
172
177
  }
173
178
 
179
+ &.shadow{
180
+ .ecs-data-card-inner{
181
+ opacity: .5;
182
+ }
183
+ }
184
+
174
185
  .control{
175
186
  margin-right: 10px;
176
187
  }
@@ -12,22 +12,22 @@
12
12
  <div v-if="$slots.headercontrols" class="ecs-overlay-header-controls">
13
13
  <slot name="headercontrols"></slot>
14
14
  </div>
15
- <ecs-button-toolbar v-if="$slots.sidebar && width <= 1400" @click="sidebarToggle" :icon="sidebarIcon" :title="showSidebar ? 'Hide ' + sidebarTitle : 'Show ' + sidebarTitle" :active="showSidebar" :badge="sidebarIconBadge" class="sidebar-button" />
15
+ <ecs-button-toolbar v-if="$slots.sidebar && width <= 1500" @click="sidebarToggle" :icon="sidebarIcon" :title="showSidebar ? 'Hide ' + sidebarTitle : 'Show ' + sidebarTitle" :active="showSidebar" :badge="sidebarIconBadge" :badge-color="sidebarIconBadgeColor" class="sidebar-button" />
16
16
  <ecs-button-toolbar @click="$emit('close')" :disabled="closeDisabled" icon="close">{{ closeText }}</ecs-button-toolbar>
17
17
  </div>
18
18
  <div ref="content" class="ecs-overlay-content scrollbar">
19
19
  <div v-if="$slots.tabs" class="ecs-overlay-tabs scrollbar scrollbar-sml">
20
20
  <slot name="tabs"></slot>
21
21
  </div>
22
- <div class="ecs-overlay-content-inner">
23
- <div class="ecs-overlay-content-inner-inner" :class="$slots.sidebar && !fullWidth && width > 1400 ? 'has-sidebar' : ' '" :style="{ width: contentWidth, maxWidth: contentMaxWidth, minWidth: contentMinWidth }">
22
+ <div class="ecs-overlay-content-inner scrollbar" :class="sidebarOpenClass">
23
+ <div class="ecs-overlay-content-inner-inner" :class="$slots.sidebar && !fullWidth && width > 1500 ? 'has-sidebar' : ' '" :style="{ width: contentWidth, maxWidth: contentMaxWidth, minWidth: contentMinWidth }">
24
24
  <slot></slot>
25
25
  </div>
26
- <div v-if="$slots.sidebar && width > 1400" class="ecs-overlay-sidebar ecs-overlay-sidebar-static">
26
+ <div v-if="$slots.sidebar && width > 1500" class="ecs-overlay-sidebar ecs-overlay-sidebar-static">
27
27
  <slot name="sidebar"></slot>
28
28
  </div>
29
29
  <transition name="slide">
30
- <div v-if="$slots.sidebar && width <= 1400 && showSidebar" class="ecs-overlay-sidebar ecs-overlay-sidebar-float scrollbar scrollbar-sml">
30
+ <div v-if="$slots.sidebar && width <= 1500 && showSidebar" class="ecs-overlay-sidebar ecs-overlay-sidebar-float scrollbar scrollbar-sml">
31
31
  <slot name="sidebar"></slot>
32
32
  </div>
33
33
  </transition>
@@ -39,7 +39,7 @@
39
39
  <div class="ecs-overlay-footer-content-inner" :style="{ width: contentWidth, maxWidth: contentMaxWidth, minWidth: contentMinWidth }">
40
40
  <slot name="footer"></slot>
41
41
  </div>
42
- <div v-if="$slots.sidebar && width > 1400" class="spacer-sidebar" />
42
+ <div v-if="$slots.sidebar && width > 1500" class="spacer-sidebar" />
43
43
  </div>
44
44
  </div>
45
45
  </div>
@@ -99,6 +99,10 @@
99
99
  sidebarIconBadge: {
100
100
  type: Boolean,
101
101
  default: false
102
+ },
103
+ sidebarIconBadgeColor: {
104
+ type: String,
105
+ default: '#FF4B62'
102
106
  }
103
107
  },
104
108
 
@@ -129,12 +133,18 @@
129
133
 
130
134
  contentMinWidth(){
131
135
  if(this.$slots.tabs && this.$slots.sidebar){
132
- return 'calc(100vw - 260px - 400px)'
136
+ return 'calc(100vw - 260px - 420px)'
133
137
  } else if(this.fullWidth && this.$slots.tabs){
134
138
  return 'calc(100vw - 260px)'
135
139
  } else {
136
140
  return '780px'
137
141
  }
142
+ },
143
+
144
+ sidebarOpenClass(){
145
+ if(this.showSidebar && this.width < 1500){
146
+ return 'sidebar-open'
147
+ }
138
148
  }
139
149
  },
140
150
 
@@ -210,11 +220,16 @@
210
220
  &-content{
211
221
  flex: 1;
212
222
  display: flex;
213
- overflow: auto;
223
+ overflow: hidden;
214
224
  position: relative;
215
225
 
216
226
  &.overflow-hidden{
217
- overflow: hidden;
227
+ overflow: hidden !important;
228
+
229
+ .ecs-overlay-content-inner,
230
+ .ecs-overlay-content-inner-inner{
231
+ overflow: hidden !important;
232
+ }
218
233
  }
219
234
  }
220
235
 
@@ -225,10 +240,10 @@
225
240
  height: 100%;
226
241
  min-height: min-content;
227
242
  position: relative;
243
+ overflow: auto;
228
244
 
229
245
  &-inner{
230
246
  position: relative;
231
- height: min-content;
232
247
  margin: 0 auto;
233
248
  height: 100%;
234
249
 
@@ -236,6 +251,14 @@
236
251
  margin: 0 0 0 auto;
237
252
  }
238
253
  }
254
+
255
+ &.sidebar-open{
256
+ overflow: hidden;
257
+
258
+ .ecs-overlay-content-inner-inner{
259
+ overflow: auto;
260
+ }
261
+ }
239
262
  }
240
263
 
241
264
  &-tabs{
@@ -255,6 +278,7 @@
255
278
  padding: 0 15px 0 30px;
256
279
  width: 400px;
257
280
  margin: 0 auto 0 0;
281
+ height: min-content;
258
282
  }
259
283
 
260
284
  &-sidebar-float{
@@ -337,6 +361,16 @@
337
361
  }
338
362
  }
339
363
 
364
+ @media only screen and (min-width: 1500px) {
365
+ .ecs-overlay-content{
366
+ overflow: auto;
367
+ }
368
+
369
+ .ecs-overlay-content-inner-inner{
370
+ overflow: initial;
371
+ }
372
+ }
373
+
340
374
  .fade-enter-active,
341
375
  .fade-leave-active{
342
376
  transition: all .3s;
@@ -12,7 +12,11 @@
12
12
  </div>
13
13
  </h3>
14
14
 
15
- <div class="ecs-section-content" :class="title ? '' : 'ecs-section-content-equal'">
15
+ <div class="ecs-section-content"
16
+ :class="[
17
+ title ? '' : 'equal',
18
+ condensed ? 'condensed' : '',
19
+ ]">
16
20
  <slot></slot>
17
21
  </div>
18
22
  </div>
@@ -42,6 +46,10 @@
42
46
  },
43
47
  headlineBold: {
44
48
  type: Boolean
49
+ },
50
+ condensed: {
51
+ type: Boolean,
52
+ default: false
45
53
  }
46
54
  },
47
55
 
@@ -112,9 +120,18 @@
112
120
  padding-top: 15px;
113
121
  padding-bottom: 25px;
114
122
 
115
- &-equal{
123
+ &.equal{
116
124
  padding-top: 25px;
117
125
  }
126
+
127
+ &.condensed{
128
+ padding-top: 5px;
129
+ padding-bottom: 15px;
130
+
131
+ &.equal{
132
+ padding-top: 15px;
133
+ }
134
+ }
118
135
  }
119
136
 
120
137
  &-indent-md,
@@ -159,9 +176,18 @@
159
176
  padding-top: 10px;
160
177
  padding-bottom: 20px;
161
178
 
162
- &-equal{
179
+ &.equal{
163
180
  padding-top: 20px;
164
181
  }
182
+
183
+ &.condensed{
184
+ padding-top: 0;
185
+ padding-bottom: 10px;
186
+
187
+ &.equal{
188
+ padding-top: 10px;
189
+ }
190
+ }
165
191
  }
166
192
  }
167
193
 
@@ -8,7 +8,7 @@ export default {
8
8
 
9
9
  export const regular = () => ({
10
10
  components: { EcsButtonToolbar },
11
- template: `<ecs-button-toolbar icon="marker"></ecs-button-toolbar>`,
11
+ template: `<ecs-button-toolbar loading icon="marker"></ecs-button-toolbar>`,
12
12
  });
13
13
 
14
14
  export const regularText = () => ({
@@ -24,6 +24,10 @@ export const states = () => ({
24
24
  <span>Added last 2 months</span>
25
25
  <span class="subtle">4h ago</span>
26
26
  </ecs-data-card>
27
+ <ecs-data-card shadow>
28
+ <span>Added last 2 months</span>
29
+ <span class="subtle">4h ago</span>
30
+ </ecs-data-card>
27
31
  <ecs-button-more type="expand">Show More</ecs-button-more>
28
32
  </ecs-data-card-list>`
29
33
  });
@@ -38,6 +38,10 @@ If more than one data card is used in a list-like structure, they should be wrap
38
38
  <span>Added last 2 months</span>
39
39
  <span class="subtle">4h ago</span>
40
40
  </ecs-data-card>
41
+ <ecs-data-card shadow>
42
+ <span>Added last 2 months</span>
43
+ <span class="subtle">4h ago</span>
44
+ </ecs-data-card>
41
45
  ```
42
46
 
43
47
  ## Content Types
@@ -109,7 +109,7 @@ export const overlayTabsSidebar = () => ({
109
109
  <button @click="showOverlay = true">Show Overlay</button>
110
110
  <ecs-overlay :show="showOverlay" @close="showOverlay = false" icon="archive" header-title="Title" header-title-emphasized="Overlay:" header-title-subline="John G. Deposition (10/12/2020) – Pages 1 - 321" sidebar-icon-badge>
111
111
 
112
- content area
112
+ <div style="height:800px;background:gray">content area</div>
113
113
 
114
114
  <template slot="tabs">tab area</template>
115
115
  <template slot="sidebar"><div style="height:500px;background:gray">sidebar area</div></template>