@everchron/ec-shards 0.6.48 → 0.6.52

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.6.48",
3
+ "version": "0.6.52",
4
4
  "private": false,
5
5
  "description": "Everchron Shards UI Library",
6
6
  "repository": "https://github.com/everchron/ec-shards.git",
Binary file
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="30" height="30" viewBox="0 0 30 30"><g fill="none" fill-rule="evenodd" transform="translate(4 2)"><rect width="22" height="26" y="1" fill="#9599AF" fill-opacity=".12" rx="2"/><rect width="22" height="26" fill="#9599AF" fill-opacity=".25" rx="2"/><rect width="20" height="24" x="1" y="1" fill="#FFF" rx="1"/><rect width="8" height="1" x="11" y="4" fill="#7A7F9A" rx=".5"/><rect width="6" height="1" x="11" y="7" fill="#9599AF" fill-opacity=".6" rx=".5"/><rect width="12" height="1" x="7" y="12" fill="#76E2AD" rx=".5"/><rect width="2" height="1" x="3" y="12" fill="#ACEDCD" rx=".5"/><rect width="2" height="1" x="3" y="15" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="2" height="1" x="3" y="18" fill="#A7CFFF" rx=".5"/><rect width="2" height="1" x="3" y="21" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="9" height="1" x="7" y="15" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="11" height="1" x="7" y="18" fill="#6BAFFF" rx=".5"/><rect width="7" height="1" x="7" y="21" fill="#9599AF" fill-opacity=".5" rx=".5"/><polygon fill="#9599AF" fill-rule="nonzero" points="6.41 9 6.41 4.516 8.039 4.516 8.039 3.363 3.355 3.363 3.355 4.516 4.98 4.516 4.98 9"/></g></svg>
@@ -0,0 +1 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" width="30" height="30" viewBox="0 0 30 30"><g fill="none" fill-rule="evenodd" transform="translate(4 2)"><rect width="22" height="26" y="1" fill="#9599AF" fill-opacity=".12" rx="2"/><rect width="22" height="26" fill="#9599AF" fill-opacity=".25" rx="2"/><rect width="20" height="24" x="1" y="1" fill="#FFF" rx="1"/><rect width="20" height="1" x="1" y="13" fill="#DFE0E7"/><rect width="1" height="24" x="10.5" y="1" fill="#DFE0E7"/><rect width="4" height="1" x="5" y="16" fill="#6BAFFF" rx=".5"/><rect width="2" height="1" x="2" y="16" fill="#A7CFFF" rx=".5"/><rect width="2" height="1" x="2" y="18" fill="#A7CFFF" rx=".5"/><rect width="2" height="1" x="2" y="20" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="3" height="1" x="5" y="18" fill="#6BAFFF" rx=".5"/><rect width="3" height="1" x="5" y="20" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="2" height="1" x="2" y="22" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="3" height="1" x="5" y="22" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="4" height="1" x="16" y="16" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="2" height="1" x="13" y="16" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="2" height="1" x="13" y="18" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="2" height="1" x="13" y="20" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="3" height="1" x="16" y="18" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="3" height="1" x="16" y="20" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="2" height="1" x="13" y="22" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="3" height="1" x="16" y="22" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="4" height="1" x="16" y="3" fill="#9599AF" fill-opacity=".5" rx=".5"/><rect width="2" height="1" x="13" y="3" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="2" height="1" x="13" y="5" fill="#ACEDCD" rx=".5"/><rect width="2" height="1" x="13" y="7" fill="#ACEDCD" rx=".5"/><rect width="3" height="1" x="16" y="5" fill="#76E2AD" rx=".5"/><rect width="3" height="1" x="16" y="7" fill="#76E2AD" rx=".5"/><rect width="2" height="1" x="13" y="9" fill="#9599AF" fill-opacity=".3" rx=".5"/><rect width="3" height="1" x="16" y="9" fill="#9599AF" fill-opacity=".5" rx=".5"/><polygon fill="#9599AF" fill-rule="nonzero" points="6.41 9 6.41 4.516 8.039 4.516 8.039 3.363 3.355 3.363 3.355 4.516 4.98 4.516 4.98 9"/></g></svg>
@@ -20,6 +20,8 @@
20
20
  'rtf',
21
21
  'transcript-mini',
22
22
  'transcript',
23
+ 'transcript-mini-highlights',
24
+ 'transcript-highlights',
23
25
  'video',
24
26
  'xls',
25
27
  'zip'
@@ -62,6 +62,10 @@
62
62
  color: darken($blue-10, 10%);
63
63
  }
64
64
  }
65
+
66
+ &.error{
67
+ color: $red-9;
68
+ }
65
69
  }
66
70
 
67
71
  .ecs-form-check-group .ecs-form-text{
@@ -0,0 +1,52 @@
1
+ <template>
2
+ <div class="ecs-form-set" :class="error ? 'error' : ''">
3
+ <h5 class="ecs-form-set-title">{{ title }}</h5>
4
+ <slot></slot>
5
+ </div>
6
+ </template>
7
+
8
+ <script>
9
+ export default {
10
+ props: {
11
+ error: {
12
+ type: Boolean,
13
+ default: false
14
+ },
15
+ title: {
16
+ type: String,
17
+ required: true
18
+ }
19
+ }
20
+ }
21
+ </script>
22
+
23
+ <style lang="scss" scoped>
24
+ @import "../tokens/tokens";
25
+ @import "../mixins/svg-uri";
26
+
27
+ .ecs-form-set{
28
+ border: 1px solid $gray-3;
29
+ border-radius: 6px;
30
+ position: relative;
31
+ padding: 25px 20px 20px 20px;
32
+
33
+ &-title{
34
+ position: absolute;
35
+ font-size: 14px;
36
+ color: $gray-8;
37
+ padding: 0 10px;
38
+ left: 10px;
39
+ top: -9px;
40
+ background: #FFF;
41
+ }
42
+
43
+ &.error{
44
+ border-color: $red-10;
45
+
46
+ .ecs-form-set-title{
47
+ color: $red-10;
48
+ }
49
+ }
50
+ }
51
+
52
+ </style>
@@ -40,6 +40,7 @@ import EcsFormCheck from "./form-check/form-check.vue"
40
40
  import EcsFormGroup from "./form-group/form-group.vue"
41
41
  import EcsFormHeadline from "./form-headline/form-headline.vue"
42
42
  import EcsFormatted from "./formatted/formatted.vue"
43
+ import EcsFormSet from "./form-set/form-set.vue"
43
44
  import EcsIcon from "./icon/icon.vue"
44
45
  import EcsIndexToolbar from "./index-toolbar/index-toolbar.vue"
45
46
  import EcsInfoTooltip from "./info-tooltip/info-tooltip.vue"
@@ -143,6 +144,7 @@ const Components = {
143
144
  EcsFormGroup,
144
145
  EcsFormHeadline,
145
146
  EcsFormatted,
147
+ EcsFormSet,
146
148
  EcsIcon,
147
149
  EcsIndexToolbar,
148
150
  EcsInfoTooltip,
@@ -3,6 +3,7 @@
3
3
  @input="$emit('input', $event)"
4
4
  @change="$emit('change', $event)"
5
5
  @keyup="$emit('keyup', $event)"
6
+ @blur="$emit('blur', $event)"
6
7
  :type="type"
7
8
  :name="name"
8
9
  :disabled="disabled"
@@ -14,7 +15,8 @@
14
15
  :class="[
15
16
  sizeClass,
16
17
  formatClass,
17
- subtle ? `ecs-form-control-subtle` : null
18
+ subtle ? 'ecs-form-control-subtle' : null,
19
+ error ? 'ecs-form-control-error' : null
18
20
  ]"
19
21
  v-bind="$attrs"
20
22
  :min="min"
@@ -25,6 +27,7 @@
25
27
  @input="$emit('input', $event)"
26
28
  @change="$emit('change', $event)"
27
29
  @keyup="$emit('keyup', $event)"
30
+ @blur="$emit('blur', $event)"
28
31
  :name="name"
29
32
  :disabled="disabled"
30
33
  :required="required"
@@ -34,7 +37,8 @@
34
37
  sizeClass,
35
38
  formatClass,
36
39
  cssClass,
37
- subtle ? `ecs-form-control-subtle` : null
40
+ subtle ? 'ecs-form-control-subtle' : null,
41
+ error ? 'ecs-form-control-error' : null
38
42
  ]"
39
43
  v-bind="$attrs"
40
44
  :ref="refr"
@@ -89,6 +93,10 @@
89
93
  type: Boolean,
90
94
  default: false
91
95
  },
96
+ error: {
97
+ type: Boolean,
98
+ default: false
99
+ },
92
100
  cssClass: String,
93
101
  refr: String,
94
102
  min: Number
@@ -177,6 +185,12 @@
177
185
  font-family: $mono;
178
186
  }
179
187
 
188
+ &-error,
189
+ &-error:focus{
190
+ box-shadow: none;
191
+ border-color: $red-9;
192
+ }
193
+
180
194
  &::placeholder {
181
195
  color: $gray-8;
182
196
  opacity: 1;
@@ -0,0 +1,16 @@
1
+ import EcsFormSet from '@components/form-set/form-set';
2
+
3
+ export default {
4
+ title: 'Forms/Form Set',
5
+ component: EcsFormSet
6
+ };
7
+
8
+ export const formSet = () => ({
9
+ components: { EcsFormSet },
10
+ template: `<ecs-form-set title="Form Set">Default Slot</ecs-form-set>`,
11
+ });
12
+
13
+ export const formSetError = () => ({
14
+ components: { EcsFormSet },
15
+ template: `<ecs-form-set error title="Form Set">Default Slot</ecs-form-set>`,
16
+ });
@@ -0,0 +1,36 @@
1
+ import { Meta, Story, ArgsTable, Canvas, Description } from '@storybook/addon-docs/blocks';
2
+ import EcsFormSet from '@components/form-set/form-set';
3
+ import * as stories from './form-set.stories.js';
4
+
5
+ <Meta
6
+ title="Forms/Form Set"
7
+ component={EcsFormSet} />
8
+
9
+ # Form Set `EcsFormSet`
10
+
11
+ Form sets are wrapping containers for multiple form elements. They can be used to bring more structure to large forms.
12
+
13
+ <Canvas withSource="none" withToolbar={true}>
14
+ <Story name="Form Set" height="50px">
15
+ {stories.formSet()}
16
+ </Story>
17
+ </Canvas>
18
+
19
+ ```js
20
+ <ecs-form-set title="Form Set">Default Slot</ecs-form-set>
21
+ ```
22
+
23
+ <Canvas withSource="none" withToolbar={true}>
24
+ <Story name="Form Set Error" height="50px">
25
+ {stories.formSetError()}
26
+ </Story>
27
+ </Canvas>
28
+
29
+ ```js
30
+ <ecs-form-set error title="Form Set">Default Slot</ecs-form-set>
31
+ ```
32
+
33
+
34
+ ## Props
35
+
36
+ <ArgsTable of={EcsFormSet} />
@@ -43,4 +43,4 @@ export const inputFormat = () => ({
43
43
  template: `<div>
44
44
  <ecs-input placeholder="Enter some ID" format="id" />
45
45
  </div>`,
46
- });
46
+ });
@@ -17,7 +17,9 @@ Radiobuttons are used for selecting a single value from several options.
17
17
  </Canvas>
18
18
 
19
19
  ```js
20
-
20
+ <ecs-radiobutton name="fruits" v-model="selected" value="orange">Label</ecs-radiobutton>
21
+ <ecs-radiobutton name="fruits" v-model="selected" value="apple" checked>Checked</ecs-radiobutton>
22
+ <ecs-radiobutton name="fruits" v-model="selected" value="grape" disabled>Disabled</ecs-radiobutton>
21
23
  ```
22
24
 
23
25
  ## Inline
@@ -31,10 +33,10 @@ If more than one radiobutton should be placed within one row, use the `inline` a
31
33
  </Canvas>
32
34
 
33
35
  ```js
34
- <ecs-checkbox inline name="fruits">Apple</ecs-checkbox>
35
- <ecs-checkbox inline name="fruits" checked>Orange</ecs-checkbox>
36
+ <ecs-radiobutton inline name="fruity" v-model="selected" value="apples">Apples</ecs-radiobutton>
37
+ <ecs-radiobutton inline name="fruity" v-model="selected" value="oranges">Oranges</ecs-radiobutton>
36
38
  ```
37
39
 
38
40
  ## Props, Slots and Events
39
41
 
40
- <ArgsTable of={EcsRadiobutton} />
42
+ <ArgsTable of={EcsRadiobutton} />