pallote-react 0.2.25 → 0.2.27

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 (35) hide show
  1. package/dist/components/Display.js +2 -2
  2. package/dist/components/Input.js +1 -1
  3. package/package.json +2 -2
  4. package/dist/styles/common/_global.scss +0 -98
  5. package/dist/styles/common/_mixins.scss +0 -58
  6. package/dist/styles/common/_variables.scss +0 -222
  7. package/dist/styles/components/accordion.scss +0 -181
  8. package/dist/styles/components/button.scss +0 -210
  9. package/dist/styles/components/buttons.scss +0 -56
  10. package/dist/styles/components/card.scss +0 -243
  11. package/dist/styles/components/checkbox.scss +0 -78
  12. package/dist/styles/components/chip.scss +0 -77
  13. package/dist/styles/components/component.scss +0 -17
  14. package/dist/styles/components/detail.scss +0 -36
  15. package/dist/styles/components/divider.scss +0 -54
  16. package/dist/styles/components/form-field.scss +0 -262
  17. package/dist/styles/components/link.scss +0 -36
  18. package/dist/styles/components/loader.scss +0 -131
  19. package/dist/styles/components/modal.scss +0 -112
  20. package/dist/styles/components/nav-group.scss +0 -72
  21. package/dist/styles/components/nav-item.scss +0 -127
  22. package/dist/styles/components/navbar.scss +0 -41
  23. package/dist/styles/components/page.scss +0 -48
  24. package/dist/styles/components/radio.scss +0 -58
  25. package/dist/styles/components/section.scss +0 -169
  26. package/dist/styles/components/snippet.scss +0 -79
  27. package/dist/styles/components/stepper.scss +0 -78
  28. package/dist/styles/components/switch.scss +0 -71
  29. package/dist/styles/components/table.scss +0 -167
  30. package/dist/styles/components/tabs.scss +0 -102
  31. package/dist/styles/components/tag.scss +0 -41
  32. package/dist/styles/components/tooltip.scss +0 -65
  33. package/dist/styles/mixins/layer.scss +0 -109
  34. package/dist/styles/mixins/text.scss +0 -150
  35. /package/dist/{styles/index.scss → index.scss} +0 -0
@@ -42,7 +42,7 @@ const Display = _ref => {
42
42
  };
43
43
  exports.Display = Display;
44
44
  Display.propTypes = {
45
- show: _propTypes.default.oneOf(['mobile-sm', 'mobile', 'tablet', 'laptop', 'desktop']),
46
- hide: _propTypes.default.oneOf(['mobile-sm', 'mobile', 'tablet', 'laptop', 'desktop']),
45
+ show: _propTypes.default.oneOf(['mobile-sm', 'mobile', 'tablet', 'laptop', 'desktop', 'touch']),
46
+ hide: _propTypes.default.oneOf(['mobile-sm', 'mobile', 'tablet', 'laptop', 'desktop', 'touch']),
47
47
  children: _propTypes.default.any
48
48
  };
@@ -52,7 +52,7 @@ const Input = _ref => {
52
52
  'js--error': error,
53
53
  'input--disabled': disabled,
54
54
  'input--required': required,
55
- 'input--withIcon': customIcon
55
+ 'input--withIcon': icon
56
56
  }, className]),
57
57
  onChange: onChange,
58
58
  onFocus: event => {
package/package.json CHANGED
@@ -4,7 +4,7 @@
4
4
  "author": {
5
5
  "name": "arnymax"
6
6
  },
7
- "version": "0.2.25",
7
+ "version": "0.2.27",
8
8
  "private": false,
9
9
  "keywords": [
10
10
  "react",
@@ -30,6 +30,7 @@
30
30
  "@testing-library/user-event": "^13.5.0",
31
31
  "classnames": "^2.3.2",
32
32
  "eslint": "^8.48.0",
33
+ "pallote-css": "^0.2.41",
33
34
  "react": "^18.2.0",
34
35
  "react-dom": "^18.2.0",
35
36
  "react-router-dom": "^6.15.0",
@@ -83,7 +84,6 @@
83
84
  "babel-plugin-named-exports-order": "^0.0.2",
84
85
  "chromatic": "^11.3.0",
85
86
  "eslint-plugin-storybook": "^0.6.13",
86
- "pallote-css": "^0.2.37",
87
87
  "prop-types": "^15.8.1",
88
88
  "storybook": "^7.4.0",
89
89
  "webpack": "^5.88.2"
@@ -1,98 +0,0 @@
1
- // —————————————————————————————————————————————————————————————————
2
- // padding & margin
3
- // —————————————————————————————————————————————————————————————————
4
-
5
- .m-05 { margin: $spacing*0.5 !important; }
6
- .mt-05 { margin-top: $spacing*0.5 !important; }
7
- .mr-05 { margin-right: $spacing*0.5 !important; }
8
- .mb-05 { margin-bottom: $spacing*0.5 !important; }
9
- .ml-05 { margin-left: $spacing*0.5 !important; }
10
-
11
- .p-05 { padding: $spacing*0.5 !important; }
12
- .pt-05 { padding-top: $spacing*0.5 !important; }
13
- .pr-05 { padding-right: $spacing*0.5 !important; }
14
- .pb-05 { padding-bottom: $spacing*0.5 !important; }
15
- .pl-05 { padding-left: $spacing*0.5 !important; }
16
-
17
- @for $i from 0 through 20 {
18
-
19
- .zi-#{$i} { z-index: $i !important; }
20
-
21
- .m-#{$i} { margin: $i*$spacing !important; }
22
- .mt-#{$i} { margin-top: $i*$spacing !important; }
23
- .mr-#{$i} { margin-right: $i*$spacing !important; }
24
- .mb-#{$i} { margin-bottom: $i*$spacing !important; }
25
- .ml-#{$i} { margin-left: $i*$spacing !important; }
26
-
27
- .p-#{$i} { padding: $i*$spacing !important; }
28
- .pt-#{$i} { padding-top: $i*$spacing !important; }
29
- .pr-#{$i} { padding-right: $i*$spacing !important; }
30
- .pb-#{$i} { padding-bottom: $i*$spacing !important; }
31
- .pl-#{$i} { padding-left: $i*$spacing !important; }
32
- }
33
-
34
- // —————————————————————————————————————————————————————————————————
35
- // width
36
- // —————————————————————————————————————————————————————————————————
37
-
38
- $max: 100;
39
- $step: 5;
40
-
41
- @for $i from 1 through (calc($max/$step)) {
42
- $value: $i * $step;
43
-
44
- .w-#{$value} {
45
- width: $value + 0% !important;
46
- }
47
- }
48
-
49
- .w {
50
-
51
- &-mobile-sm { width: $mobile-sm-up !important; }
52
- &-mobile { width: $mobile-up !important; }
53
- &-tablet { width: $tablet-up !important; }
54
- &-laptop { width: $laptop-up !important; }
55
- &-desktop { width: $desktop-up !important; }
56
- }
57
-
58
- // —————————————————————————————————————————————————————————————————
59
- // misc
60
- // —————————————————————————————————————————————————————————————————
61
-
62
- .dp {
63
-
64
- &-inline { display: inline !important; }
65
- &-block { display: block !important; }
66
- &-flex { display: flex !important; }
67
- &-grid { display: grid !important; }
68
- &-inline-block { display: inline-block !important; }
69
- &-inline-flex { display: inline-flex !important; }
70
- &-inline-grid { display: inline-grid !important; }
71
- &-none { display: none !important; }
72
- &-initial { display: initial !important; }
73
- &-inheri { display: inheri !important; }
74
- }
75
-
76
- .of {
77
-
78
- &-visible { overflow: visible !important; }
79
- &-hidden { overflow: hidden !important; }
80
- &-scroll { overflow: scroll !important; }
81
- &-auto { overflow: auto !important; }
82
-
83
- &X {
84
-
85
- &-visible { overflow-x: visible !important; }
86
- &-hidden { overflow-x: hidden !important; }
87
- &-scroll { overflow-x: scroll !important; }
88
- &-auto { overflow-x: auto !important; }
89
- }
90
-
91
- &Y {
92
-
93
- &-visible { overflow-y: visible !important; }
94
- &-hidden { overflow-y: hidden !important; }
95
- &-scroll { overflow-y: scroll !important; }
96
- &-auto { overflow-y: auto !important; }
97
- }
98
- }
@@ -1,58 +0,0 @@
1
- // —————————————————————————————————————————————————————————————————
2
- // misc
3
- // media queries
4
- // —————————————————————————————————————————————————————————————————
5
-
6
- // —————————————————————————————————————————————————————————————————
7
- // misc
8
- // —————————————————————————————————————————————————————————————————
9
-
10
- @mixin calc($property, $expression) {
11
- #{$property}: -webkit-calc(#{$expression});
12
- #{$property}: calc(#{$expression});
13
- }
14
-
15
- @mixin hover {
16
- &:hover, &:active, &:focus {
17
- @content;
18
- }
19
- }
20
-
21
- // —————————————————————————————————————————————————————————————————
22
- // media queries
23
- // —————————————————————————————————————————————————————————————————
24
-
25
- @mixin responsive($value, $breakpoint) {
26
- @if $value == up {
27
- $value: min-width;
28
- @if $breakpoint == desktop { $breakpoint: $desktop-up; }
29
- @else if $breakpoint == laptop { $breakpoint: $laptop-up; }
30
- @else if $breakpoint == tablet { $breakpoint: $tablet-up; }
31
- @else if $breakpoint == mobile { $breakpoint: $mobile-up; }
32
- @else if $breakpoint == mobile-sm { $breakpoint: $mobile-sm-up; }
33
-
34
- } @else if $value == down {
35
- $value: max-width;
36
- @if $breakpoint == desktop { $breakpoint: $desktop-down; }
37
- @else if $breakpoint == laptop { $breakpoint: $laptop-down; }
38
- @else if $breakpoint == tablet { $breakpoint: $tablet-down; }
39
- @else if $breakpoint == mobile { $breakpoint: $mobile-down; }
40
- @else if $breakpoint == mobile-sm { $breakpoint: $mobile-sm-down; }
41
- }
42
-
43
- @media ($value: $breakpoint) {
44
- @content;
45
- }
46
- }
47
-
48
- @mixin responsive-touch() {
49
- @media (pointer: coarse) {
50
- @content;
51
- }
52
- }
53
-
54
- @mixin responsive-mobile-landscape {
55
- @media only screen and (max-device-width: $laptop-down) and (orientation: landscape) {
56
- @content;
57
- }
58
- }
@@ -1,222 +0,0 @@
1
- // —————————————————————————————————————————————————————————————————
2
- // colors
3
- // spacing
4
- // typography
5
- // breakpoints
6
- // misc
7
- // —————————————————————————————————————————————————————————————————
8
-
9
- // —————————————————————————————————————————————————————————————————
10
- // colors
11
- // —————————————————————————————————————————————————————————————————
12
-
13
- // common
14
-
15
- $black: #000A1E !default;
16
- $white: #FFFFFF !default;
17
-
18
- // grey gradient
19
-
20
- $grey-90: #1A2335 !default;
21
- $grey-80: #333B4B !default;
22
- $grey-70: #4D5462 !default;
23
- $grey-60: #666C78 !default;
24
- $grey-50: #7F848E !default;
25
- $grey-40: #999DA5 !default;
26
- $grey-30: #B2B5BB !default;
27
- $grey-20: #CCCED2 !default;
28
- $grey-10: #E5E6E8 !default;
29
- $grey-5: #F2F3F4 !default;
30
-
31
- // text
32
-
33
- $text: $white !default;
34
- $text-alt: rgba($text, 0.66) !default;
35
- $text-disabled: rgba($text, 0.33) !default;
36
- $text-contrast: $black !default;
37
- $text-contrast-alt: rgba($text-contrast, 0.66) !default;
38
- $text-contrast-disabled: rgba($text-contrast, 0.33) !default;
39
-
40
- // brand
41
-
42
- $primary: #00F3FF !default;
43
- $primary-light: mix($white, $primary, 70%) !default;
44
- $primary-dark: mix($black, $primary, 50%) !default;
45
- $primary-text-contrast: $text-contrast !default;
46
-
47
- $secondary: #E7FC00 !default;
48
- $secondary-light: mix($white, $secondary, 70%) !default;
49
- $secondary-dark: mix($black, $secondary, 50%) !default;
50
- $secondary-text-contrast: $text-contrast !default;
51
-
52
- $highlight: #FF74E6 !default;
53
- $highlight-light: mix($white, $highlight, 70%) !default;
54
- $highlight-dark: mix($black, $highlight, 50%) !default;
55
- $highlight-text-contrast: $text-contrast !default;
56
-
57
- // misc
58
-
59
- $background: $black !default;
60
- $paper: $grey-90 !default;
61
-
62
- $overlay: rgba($white, 0.1) !default;
63
- $hover: rgba($white, 0.08) !default;
64
- $backdrop: rgba($white, 0.2) !default;
65
-
66
- $border: rgba($white, 0.2) !default;
67
- $border-contrast: rgba($black, 0.2) !default;
68
-
69
- // feedback
70
-
71
- $success-light: #E7F9EE !default;
72
- $success: #26a95d !default;
73
- $success-dark: #1C7C44 !default;
74
- $success-text: #155F34 !default;
75
- $success-text-contrast: $text !default;
76
-
77
- $info-light: #E9F8FD !default;
78
- $info: #17A0CC !default;
79
- $info-dark: #117798 !default;
80
- $info-text: #0D5A72 !default;
81
- $info-text-contrast: $text !default;
82
-
83
- $warning-light: #FFFAE5 !default;
84
- $warning: #FFDC46 !default;
85
- $warning-dark: #886E00 !default;
86
- $warning-text: #685400 !default;
87
- $warning-text-contrast: $text-contrast !default;
88
-
89
- $error-light: #FCE7E7 !default;
90
- $error: #EB5757 !default;
91
- $error-dark: #D31919 !default;
92
- $error-text: #9C1212 !default;
93
- $error-text-contrast: $text !default;
94
-
95
- // social
96
-
97
- $facebook:#1877F2;
98
- $github:#4078C0;
99
- $instagram: #405DE6;
100
- $linkedin: #0077B5;
101
- $medium:#00AB6C;
102
- $twitter:#1DA1F2;
103
-
104
- // export for use in jsx files
105
-
106
- :export {
107
- black: $black;
108
- white: $white;
109
-
110
- grey-90: $grey-90;
111
- grey-80: $grey-80;
112
- grey-70: $grey-70;
113
- grey-60: $grey-60;
114
- grey-50: $grey-50;
115
- grey-40: $grey-40;
116
- grey-30: $grey-30;
117
- grey-20: $grey-20;
118
- grey-10: $grey-10;
119
- grey-5: $grey-5;
120
-
121
- text: $text;
122
- text-alt: $text-alt;
123
- text-disabled: $text-disabled;
124
- text-contrast: $text-contrast;
125
- text-contrast-alt: $text-contrast-alt;
126
- text-contrast-disabled: $text-contrast-disabled;
127
-
128
- primary: $primary;
129
- secondary: $secondary;
130
- highlight: $highlight;
131
-
132
- background: $background;
133
- paper: $paper;
134
- overlay: $overlay;
135
- hover: $hover;
136
- backdrop: $backdrop;
137
- border: $border;
138
- border-contrast: $border-contrast;
139
-
140
- success: $success;
141
- info: $info;
142
- warning: $warning;
143
- error: $error;
144
- }
145
-
146
- // —————————————————————————————————————————————————————————————————
147
- // spacing
148
- // —————————————————————————————————————————————————————————————————
149
-
150
- $spacing: 0.5rem !default; // 8px
151
-
152
- $page-gutter: calc(100vw / 12) !default;
153
- $page-max-width: 1200px !default;
154
- $page-column: calc(100% / 12) !default;
155
-
156
- $section-spacing: $spacing*8 !default;
157
- $section-spacing-content: $spacing*6 !default;
158
-
159
- $navbar-height: $spacing*8 !default;
160
-
161
- // —————————————————————————————————————————————————————————————————
162
- // typography
163
- // —————————————————————————————————————————————————————————————————
164
-
165
- // fonts
166
-
167
- $font: "Barlow", "Arial", sans-serif !default;
168
-
169
- // weight
170
-
171
- $font-light: 300 !default;
172
- $font-regular: 500 !default;
173
- $font-bold: 700 !default;
174
-
175
- // —————————————————————————————————————————————————————————————————
176
- // breakpoints
177
- // —————————————————————————————————————————————————————————————————
178
-
179
- $desktop-lg: 1800px !default;
180
-
181
- $desktop-up: 1280px !default;
182
- $desktop-down: 1279.98px !default;
183
-
184
- $laptop-up: 1024px !default;
185
- $laptop-down: 1023.98px !default;
186
-
187
- $tablet-up: 768px !default;
188
- $tablet-down: 767.98px !default;
189
-
190
- $mobile-up: 576px !default;
191
- $mobile-down: 575.98px !default;
192
-
193
- $mobile-sm-up: 375px !default;
194
- $mobile-sm-down: 374.98px !default;
195
-
196
- // —————————————————————————————————————————————————————————————————
197
- // misc
198
- // —————————————————————————————————————————————————————————————————
199
-
200
- // transition
201
-
202
- $transition-md: 0.4s ease 0s !default;
203
- $transition-lg: 0.8s ease 0s !default;
204
-
205
- // shadow
206
-
207
- $box-shadow-sm: 0 0 $spacing $spacing*0.25 rgba($secondary ,0.2) !default;
208
- $box-shadow-md: 0 0 $spacing*2 $spacing*0.5 rgba($secondary ,0.2) !default;
209
- $box-shadow-lg: 0 0 $spacing*4 $spacing rgba($secondary ,0.2) !default;
210
-
211
- // border
212
-
213
- $border-sm: 1px solid !default;
214
- $border-md: $spacing*0.25 solid !default;
215
- $border-lg: $spacing*0.5 solid !default;
216
-
217
- // border-radius
218
-
219
- $border-radius-sm: $spacing*0.75 !default;
220
- $border-radius-md: $spacing !default;
221
- $border-radius-lg: $spacing*2 !default;
222
-
@@ -1,181 +0,0 @@
1
- // —————————————————————————————————————————————————————————————————
2
- // mixins
3
- // elements
4
- // size
5
- // noPadding
6
- // transparent
7
- // gutter
8
- // active
9
- // disabled
10
- // —————————————————————————————————————————————————————————————————
11
-
12
- // —————————————————————————————————————————————————————————————————
13
- // mixins
14
- // —————————————————————————————————————————————————————————————————
15
-
16
- @mixin size($proportion, $size) {
17
-
18
- .accordion {
19
-
20
- &__item {
21
- border-radius: calc($size*2/3);
22
-
23
- &:not(:last-child) {
24
- margin-bottom: calc($size/3);
25
- }
26
-
27
- &--active {
28
- padding-bottom: $size;
29
- }
30
- }
31
-
32
- &__control {
33
- padding: $size $size*1.5;
34
- }
35
-
36
- &__icon {
37
- @if $proportion == lg { height: $size*1.5; width: $size*1.5; }
38
- @else { height: $size*2; width: $size*2; }
39
-
40
- &:first-child { margin-right: calc($size); }
41
- &:last-child { margin-left: calc($size); }
42
- }
43
-
44
- &__header {
45
-
46
- @if $proportion == sm { margin-bottom: -1px; }
47
- @if $proportion == lg { margin: -1px 0 -2px 0; }
48
- }
49
-
50
- &__content {
51
- transition: height $transition-md;
52
- will-change: height;
53
- padding: 0 $size*1.5;
54
- overflow: hidden;
55
- }
56
- }
57
-
58
- &.accordion--gutter .accordion__item--active {
59
- padding-bottom: $size*2;
60
-
61
- .accordion__control {
62
- padding-top: $size*2;
63
- padding-bottom: $size*2;
64
- }
65
- }
66
-
67
- &.accordion--transparent .accordion__item--active {
68
- margin-top: calc($size/3);
69
- }
70
- }
71
-
72
- // —————————————————————————————————————————————————————————————————
73
- // elements
74
- // —————————————————————————————————————————————————————————————————
75
-
76
- .accordion {
77
- width: 100%;
78
-
79
- &__item {
80
- background-color: $paper;
81
- width: 100%;
82
- }
83
-
84
- &__control,
85
- &__content {
86
- transition: padding $transition-md;
87
- will-change: paddding;
88
- }
89
-
90
- &__control {
91
- display: flex;
92
- align-items: center;
93
- width: 100%;
94
- cursor: pointer;
95
- }
96
-
97
- &__header {
98
- flex-grow: 1;
99
- text-align: left;
100
- }
101
-
102
- &__icon {
103
- display: flex;
104
- align-items: center;
105
- justify-content: center;
106
- height: 1.125rem;
107
- width: 1.125rem;
108
-
109
- &:first-child { margin-right: 0.5rem; }
110
- &:last-child { margin-left: 0.5rem; }
111
-
112
- &--arrow {
113
- transition: transform $transition-md;
114
- will-change: transform;
115
- }
116
- }
117
- }
118
-
119
- // —————————————————————————————————————————————————————————————————
120
- // size
121
- // —————————————————————————————————————————————————————————————————
122
-
123
- .accordion {
124
-
125
- &--sm { @include size(sm, $spacing*0.75); }
126
- &--md { @include size(md, $spacing); }
127
- &--lg { @include size(lg, $spacing*1.5); }
128
- }
129
-
130
- // —————————————————————————————————————————————————————————————————
131
- // transparent
132
- // —————————————————————————————————————————————————————————————————
133
-
134
- .accordion--transparent {
135
-
136
- .accordion__item {
137
- transition: background-color $transition-md, margin $transition-md;
138
- will-change: background-color, margin;
139
- background-color: transparent;
140
-
141
- @include hover { background-color: $paper; }
142
- &--active { background-color: $paper; }
143
- &--disabled { @include hover { background-color: transparent; }}
144
-
145
- &:not(:last-child):not(.accordion__item--active) {
146
- margin-bottom: 0;
147
- }
148
- }
149
- }
150
-
151
- // —————————————————————————————————————————————————————————————————
152
- // gutter
153
- // —————————————————————————————————————————————————————————————————
154
-
155
- // see size mixin
156
-
157
- // —————————————————————————————————————————————————————————————————
158
- // active
159
- // —————————————————————————————————————————————————————————————————
160
-
161
- .accordion__item--active {
162
-
163
- .accordion {
164
-
165
- &__icon--arrow {
166
- transform: rotate(180deg);
167
- }
168
- }
169
- }
170
-
171
- // —————————————————————————————————————————————————————————————————
172
- // disabled
173
- // —————————————————————————————————————————————————————————————————
174
-
175
- .accordion__item--disabled {
176
- opacity: 0.5;
177
-
178
- .accordion__control {
179
- cursor: not-allowed;
180
- }
181
- }