@magicgol/polyjuice 0.38.0 → 0.38.2

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@magicgol/polyjuice",
3
- "version": "0.38.0",
3
+ "version": "0.38.2",
4
4
  "scripts": {
5
5
  "serve": "vue-cli-service serve",
6
6
  "build": "vue-cli-service build",
@@ -3,7 +3,9 @@ $palette: (
3
3
  'brand': #d81159,
4
4
  'freemium' :#004781,
5
5
  'coin': #ffcf73,
6
- 'club': #FFCC5E,
6
+ 'club--step-1': #0df2bb,
7
+ 'club--step-2': #a714ed,
8
+ 'club': linear-gradient(134.42deg, #0df2bb 0.99%, #a714ed 100%),
7
9
  'text': #343434,
8
10
  // ALERT
9
11
  'error': #ed4949,
@@ -103,10 +103,10 @@ export default {
103
103
  }
104
104
 
105
105
  &-club {
106
- background-color: rgba(map-get($palette, 'club'), 0.05);
106
+ background: map-get($palette, 'club');
107
107
 
108
108
  svg {
109
- fill: map-get($palette, 'club');
109
+ fill: #fff;
110
110
  }
111
111
  }
112
112
 
@@ -142,7 +142,7 @@ export default {
142
142
  background-color: map-get($palette, 'club');
143
143
 
144
144
  svg {
145
- fill: mix(white, map-get($palette, 'club'), 90%);
145
+ //fill: mix(white, map-get($palette, 'club'), 90%);
146
146
  }
147
147
  }
148
148
 
@@ -13,7 +13,7 @@ export default {
13
13
  },
14
14
  theme: {
15
15
  control: { type: 'select' },
16
- options: ['light', 'dark', 'club', 'goalkeeper', 'defender', 'midfielder', 'forward', 'success'],
16
+ options: ['light', 'dark', 'club', 'trial', 'goalkeeper', 'defender', 'midfielder', 'forward', 'success'],
17
17
  defaultValue: 'light'
18
18
  },
19
19
  default: {
@@ -25,7 +25,7 @@ export default {
25
25
  type: String,
26
26
  default: 'light',
27
27
  validator: function (value) {
28
- return ['light', 'dark', 'club', 'goalkeeper', 'defender', 'midfielder', 'forward', 'success'].indexOf(value) !== -1;
28
+ return ['light', 'dark', 'club', 'trial', 'goalkeeper', 'defender', 'midfielder', 'forward', 'success'].indexOf(value) !== -1;
29
29
  },
30
30
  },
31
31
  },
@@ -39,6 +39,7 @@ export default {
39
39
  'mg-label--theme-light': this.theme === 'light',
40
40
  'mg-label--theme-dark': this.theme === 'dark',
41
41
  'mg-label--theme-club': this.theme === 'club',
42
+ 'mg-label--theme-trial': this.theme === 'trial',
42
43
  'mg-label--theme-goalkeeper': this.theme === 'goalkeeper',
43
44
  'mg-label--theme-defender': this.theme === 'defender',
44
45
  'mg-label--theme-midfielder': this.theme === 'midfielder',
@@ -92,9 +93,15 @@ export default {
92
93
  }
93
94
 
94
95
  &-club {
96
+ background: map-get($palette, 'club');
97
+ border-color: map-get($palette, 'club');
98
+ color: #fff;
99
+ }
100
+
101
+ &-trial {
95
102
  background: #fff;
96
- border-color: map-get($palette, 'club');;
97
- color: map-get($palette, 'club');;
103
+ border-color: map-get($palette, 'club');
104
+ color: map-get($palette, 'club');
98
105
  }
99
106
 
100
107
  &-goalkeeper {
@@ -75,8 +75,8 @@ export default {
75
75
 
76
76
  &--theme {
77
77
  &-club {
78
- background: linear-gradient(90deg, #D1EFFF 0%, #DDDAFC 99.65%) !important;
79
- color: #777;
78
+ background: map-get($palette, 'club');
79
+ color: #fff;
80
80
  }
81
81
 
82
82
  &-rating {
@@ -0,0 +1,33 @@
1
+ import MgIconBadge from '../../components/icon-badge/IconBadge.vue';
2
+
3
+ // More on default export: https://storybook.js.org/docs/vue/writing-stories/introduction#default-export
4
+ export default {
5
+ title: 'Context/Club/Icon Badge',
6
+ component: MgIconBadge,
7
+ // More on argTypes: https://storybook.js.org/docs/vue/api/argtypes
8
+ argTypes: {
9
+ size: {
10
+ control: { type: 'select' },
11
+ options: ['normal', 'large'],
12
+ defaultValue: 'normal'
13
+ },
14
+ },
15
+ };
16
+
17
+ // More on component templates: https://storybook.js.org/docs/vue/writing-stories/introduction#using-args
18
+ const Template = (args, { argTypes }) => ({
19
+ props: Object.keys(argTypes),
20
+ components: { MgIconBadge },
21
+ template: `<mg-icon-badge v-bind="$props"></mg-icon-badge>`,
22
+ });
23
+
24
+ export const Club = Template.bind({});
25
+ // More on args: https://storybook.js.org/docs/vue/writing-stories/args
26
+ Club.args = {
27
+ icon: 'message',
28
+ context: 'club',
29
+ size: 'normal',
30
+ active: false
31
+ };
32
+
33
+
@@ -0,0 +1,47 @@
1
+ import MgLabel from '../../components/label/Label.vue';
2
+
3
+ // More on default export: https://storybook.js.org/docs/vue/writing-stories/introduction#default-export
4
+ export default {
5
+ title: 'Context/Club/Label',
6
+ component: MgLabel,
7
+ // More on argTypes: https://storybook.js.org/docs/vue/api/argtypes
8
+ argTypes: {
9
+ size: {
10
+ control: { type: 'select' },
11
+ options: ['normal', 'small'],
12
+ defaultValue: 'normal'
13
+ },
14
+ theme: {
15
+ control: { type: 'select' },
16
+ options: ['light', 'dark', 'club', 'trial', 'goalkeeper', 'defender', 'midfielder', 'forward', 'success'],
17
+ defaultValue: 'light'
18
+ },
19
+ default: {
20
+ description: "The default Vue slot",
21
+ control: {
22
+ type: 'text',
23
+ },
24
+ table: {
25
+ category: 'Slots',
26
+ type: {
27
+ summary: 'html',
28
+ },
29
+ }
30
+ }
31
+ },
32
+ };
33
+
34
+ // More on component templates: https://storybook.js.org/docs/vue/writing-stories/introduction#using-args
35
+ const Template = (args, { argTypes }) => ({
36
+ props: Object.keys(argTypes),
37
+ components: { MgLabel },
38
+ template: `<mg-label v-bind="$props"><template v-if="${'default' in args}" v-slot>${args.default}</template></mg-label>`,
39
+ });
40
+
41
+ export const Club = Template.bind({});
42
+ // More on args: https://storybook.js.org/docs/vue/writing-stories/args
43
+ Club.args = {
44
+ default: 'etichetta',
45
+ size: 'small',
46
+ theme: 'club'
47
+ };
@@ -0,0 +1,67 @@
1
+ import MgVCard from '../../content/card/vertical-card/VCard.vue';
2
+
3
+ // More on default export: https://storybook.js.org/docs/vue/writing-stories/introduction#default-export
4
+ export default {
5
+ title: 'Context/Club/VCard',
6
+ component: MgVCard,
7
+ // More on argTypes: https://storybook.js.org/docs/vue/api/argtypes
8
+ argTypes: {
9
+ default: {
10
+ description: "The default Vue slot",
11
+ control: {
12
+ type: 'text',
13
+ },
14
+ table: {
15
+ category: 'Slots',
16
+ type: {
17
+ summary: 'html',
18
+ },
19
+ }
20
+ },
21
+ theme: {
22
+ control: { type: 'select' },
23
+ options: [
24
+ null,
25
+ 'club',
26
+ 'rating',
27
+ 'goalkeeper',
28
+ 'defender',
29
+ 'midfielder',
30
+ 'forward',
31
+ 'bench',
32
+ 'transparent',
33
+ ],
34
+ defaultValue: null
35
+ },
36
+ footer: {
37
+ description: "The footer content goes here",
38
+ control: {
39
+ type: 'text',
40
+ },
41
+ table: {
42
+ category: 'Slots',
43
+ type: {
44
+ summary: 'html',
45
+ },
46
+ }
47
+ }
48
+ },
49
+ };
50
+
51
+ // More on component templates: https://storybook.js.org/docs/vue/writing-stories/introduction#using-args
52
+ const Template = (args, { argTypes }) => ({
53
+ props: Object.keys(argTypes),
54
+ components: { MgVCard },
55
+ template: `<mg-v-card @click="$emit('click')" v-bind="$props">
56
+ <template v-if="${'default' in args}" v-slot>${args.default}</template>
57
+ <template v-if="${'footer' in args}" v-slot:footer>${args.footer}</template>
58
+ </mg-v-card>`,
59
+ });
60
+
61
+ export const Club = Template.bind({});
62
+ // More on args: https://storybook.js.org/docs/vue/writing-stories/args
63
+ Club.args = {
64
+ theme: 'club',
65
+ default: '<div>This is a vertical card.</div><div>What do you think about?</div>',
66
+ footer: '<div>The footer content goes here</div>'
67
+ };
@@ -62,7 +62,7 @@ export default {
62
62
 
63
63
  .mg-primary-club-button {
64
64
  appearance: none;
65
- background-color: map-get($palette, 'club');
65
+ background: map-get($palette, 'club');
66
66
  box-shadow: 0 5px 22px rgba(0, 0, 0, 0.3);
67
67
  cursor: pointer;
68
68
  font-family: 'Ubuntu', sans-serif;
@@ -1,14 +1,16 @@
1
1
  <template>
2
2
  <button
3
- class="d-block bg-white w-100 rounded text-uppercase text-center text-decoration-none"
3
+ class="d-block w-100 rounded text-uppercase text-center text-decoration-none"
4
4
  type="button"
5
5
  :class="classes"
6
6
  :disabled="disabled"
7
7
  @click="onClick"
8
8
  >
9
- <div class="d-flex justify-content-center align-items-center">
10
- <mg-club-star :trial="trial"></mg-club-star>
11
- <div class="ml-2"><slot></slot></div>
9
+ <div class="bg-white">
10
+ <div class="d-flex justify-content-center align-items-center">
11
+ <mg-club-star :trial="trial"></mg-club-star>
12
+ <div class="ml-2"><slot></slot></div>
13
+ </div>
12
14
  </div>
13
15
  </button>
14
16
  </template>
@@ -57,16 +59,26 @@ export default {
57
59
 
58
60
  .mg-secondary-club-button {
59
61
  appearance: none;
60
- border: 2px solid map-get($palette, 'club');
62
+ background: map-get($palette, 'club');
61
63
  box-shadow: 0 5px 22px rgba(0, 0, 0, 0.3);
62
64
  box-sizing: border-box;
63
- color: map-get($palette, 'club');
65
+ border: 0;
64
66
  cursor: pointer;
65
67
  font-size: 1rem;
66
68
  font-family: 'Ubuntu', sans-serif;
67
69
  font-weight: 500;
68
70
  outline: none;
69
- padding: calc(0.5rem - 2px);
71
+ padding: 0.125rem;
72
+
73
+ > div {
74
+ padding: calc(0.5rem - 2px);
75
+
76
+ > div {
77
+ background: map-get($palette, 'club');
78
+ -webkit-background-clip: text;
79
+ -webkit-text-fill-color: transparent;
80
+ }
81
+ }
70
82
 
71
83
  &--disabled {
72
84
  opacity: 0.3 !important;
@@ -4,6 +4,12 @@
4
4
  :class="classes"
5
5
  @click="$emit('click')"
6
6
  >
7
+ <svg style="width:0;height:0;position: absolute" aria-hidden="true" focusable="false">
8
+ <linearGradient id="mg-club-plate-gradient" x2="1" y2="1">
9
+ <stop offset="0%" class="step-1" />
10
+ <stop offset="100%" class="step-2" />
11
+ </linearGradient>
12
+ </svg>
7
13
  <svgicon
8
14
  name="star-c"
9
15
  ></svgicon>
@@ -42,13 +48,23 @@ export default {
42
48
  @import '../../../../assets/palette';
43
49
 
44
50
  .mg-club-plate {
45
- color: map-get($palette, 'club');
51
+ background: map-get($palette, 'club');
52
+ -webkit-background-clip: text;
53
+ -webkit-text-fill-color: transparent;
46
54
  font-family: 'Ubuntu', sans-serif;
47
55
  font-size: 0.75rem;
48
56
  font-weight: 700;
49
57
 
50
- svg {
51
- fill: map-get($palette, 'club');
58
+ .step-1 {
59
+ stop-color: map-get($palette, 'club--step-1');
60
+ }
61
+
62
+ .step-2 {
63
+ stop-color: map-get($palette, 'club--step-2');
64
+ }
65
+
66
+ .svg-icon {
67
+ fill: url(#mg-club-plate-gradient);
52
68
  height: 1.5rem;
53
69
  min-height: 1.5rem;
54
70
  min-width: 1.5rem;
@@ -3,7 +3,9 @@
3
3
  class="d-inline-block rounded"
4
4
  :class="classes"
5
5
  >
6
- <mg-club-star :size="size" :trial="trial" :disabled="disabled"><slot></slot></mg-club-star>
6
+ <div>
7
+ <mg-club-star :size="size" :trial="trial" :disabled="disabled"><slot></slot></mg-club-star>
8
+ </div>
7
9
  </div>
8
10
  </template>
9
11
 
@@ -54,20 +56,30 @@ export default {
54
56
  @import '../../../../assets/palette';
55
57
 
56
58
  .mg-club-square {
57
- background-color: lighten(map-get($palette, 'club'), 25%);
59
+ background: map-get($palette, 'club');
60
+
61
+ > div {
62
+ background-color: rgba(255, 255, 255, 0.9)
63
+ }
58
64
 
59
65
  &--size {
60
66
  &-small {
61
- padding: 0.25rem 0.5rem;
67
+ > div {
68
+ padding: 0.25rem 0.5rem;
69
+ }
62
70
  }
63
71
 
64
72
  &-normal {
65
- padding: 0.5rem;
73
+ > div {
74
+ padding: 0.5rem;
75
+ }
66
76
  }
67
77
  }
68
78
 
69
79
  &--disabled {
70
- background-color: #efefef;
80
+ > div {
81
+ background-color: #efefef;
82
+ }
71
83
  }
72
84
  }
73
85
  </style>
@@ -3,6 +3,12 @@
3
3
  class="d-flex align-items-center"
4
4
  :class="classes"
5
5
  >
6
+ <svg style="width:0;height:0;position: absolute" aria-hidden="true" focusable="false">
7
+ <linearGradient id="mg-club-star-gradient" x2="1" y2="1">
8
+ <stop offset="0%" class="step-1" />
9
+ <stop offset="100%" class="step-2" />
10
+ </linearGradient>
11
+ </svg>
6
12
  <svgicon v-bind:name="icon"></svgicon>
7
13
  <div v-if="slotVisibility" class="ml-2"><slot></slot></div>
8
14
  </div>
@@ -63,16 +69,26 @@ export default {
63
69
  @import '../../../../assets/palette';
64
70
 
65
71
  .mg-club-star {
66
- color: map-get($palette, 'club');
67
72
 
68
73
  div {
74
+ background: map-get($palette, 'club');
75
+ -webkit-background-clip: text;
76
+ -webkit-text-fill-color: transparent;
69
77
  font-family: Ubuntu, sans-serif;
70
78
  font-weight: 500;
71
79
  line-height: 11px;
72
80
  }
73
81
 
74
- svg {
75
- fill: map-get($palette, 'club');
82
+ .step-1 {
83
+ stop-color: map-get($palette, 'club--step-1');
84
+ }
85
+
86
+ .step-2 {
87
+ stop-color: map-get($palette, 'club--step-2');
88
+ }
89
+
90
+ .svg-icon {
91
+ fill: url(#mg-club-star-gradient);
76
92
  }
77
93
 
78
94
  &-size {
@@ -120,7 +136,7 @@ export default {
120
136
  color: #fff;
121
137
 
122
138
  svg {
123
- fill: #fff;
139
+ fill: #fff !important;
124
140
  }
125
141
  }
126
142
 
@@ -17,6 +17,6 @@ import {ColorItem, ColorPalette, Meta} from '@storybook/addon-docs';
17
17
  />
18
18
  <ColorItem
19
19
  title="Club"
20
- colors={{'Teal Blue': '#075169'}}
20
+ colors={{'Electric Violet': 'linear-gradient(134.42deg, #0DF2BB 0.99%, #A714ED 100%)'}}
21
21
  />
22
22
  </ColorPalette>