@steroidsjs/bootstrap 3.0.0-beta.3 → 3.0.0-beta.30
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/README.md +1 -2
- package/content/Accordion/AccordionItemView.d.ts +2 -0
- package/content/Accordion/AccordionItemView.js +96 -0
- package/content/Accordion/AccordionItemView.scss +209 -0
- package/content/Accordion/AccordionView.d.ts +2 -0
- package/content/{Collapse/CollapseView.js → Accordion/AccordionView.js} +3 -3
- package/content/{Collapse/CollapseView.scss → Accordion/AccordionView.scss} +3 -4
- package/content/Alert/AlertView.scss +19 -4
- package/content/Avatar/AvatarView.js +2 -3
- package/content/Avatar/AvatarView.scss +29 -36
- package/content/Badge/BadgeView.d.ts +3 -0
- package/content/Badge/BadgeView.js +25 -0
- package/content/Badge/BadgeView.scss +135 -0
- package/content/Calendar/CaptionElement.scss +5 -4
- package/content/Card/CardView.js +34 -14
- package/content/Card/CardView.scss +126 -110
- package/content/Detail/DetailView.scss +75 -52
- package/content/DropDown/DropDownView.js +6 -3
- package/content/DropDown/DropDownView.scss +196 -27
- package/content/Icon/IconView.js +2 -2
- package/form/Button/ButtonView.js +12 -8
- package/form/Button/ButtonView.scss +157 -71
- package/form/CheckboxField/CheckboxFieldView.js +6 -3
- package/form/CheckboxField/CheckboxFieldView.scss +185 -36
- package/form/DropDownField/DropDownFieldView.js +46 -47
- package/form/DropDownField/DropDownFieldView.scss +391 -181
- package/form/DropDownField/views/DropDownItem/DropDownItemView.d.ts +3 -0
- package/form/DropDownField/views/DropDownItem/DropDownItemView.js +80 -0
- package/form/DropDownField/views/DropDownItem/DropDownItemView.scss +217 -0
- package/form/DropDownField/views/DropDownItem/index.d.ts +2 -0
- package/form/DropDownField/views/DropDownItem/index.js +7 -0
- package/form/FieldLayout/FieldLayoutView.js +12 -4
- package/form/FieldLayout/FieldLayoutView.scss +128 -24
- package/form/Form/FormView.js +3 -3
- package/form/Form/FormView.scss +10 -14
- package/form/InputField/InputFieldView.js +32 -13
- package/form/InputField/InputFieldView.scss +245 -99
- package/form/NumberField/NumberFieldView.js +19 -13
- package/form/NumberField/NumberFieldView.scss +195 -89
- package/form/PasswordField/PasswordFieldView.js +11 -9
- package/form/PasswordField/PasswordFieldView.scss +231 -63
- package/form/RadioListField/RadioListFieldView.js +10 -3
- package/form/RadioListField/RadioListFieldView.scss +229 -1
- package/form/TextField/TextFieldView.js +10 -2
- package/form/TextField/TextFieldView.scss +143 -2
- package/icons/index.d.ts +2 -0
- package/{icon/fontawesome.js → icons/index.js} +37 -11
- package/icons/svgs/accordion-chevron.svg +4 -0
- package/icons/svgs/arrow.svg +3 -0
- package/icons/svgs/badge-close.svg +3 -0
- package/icons/svgs/close.svg +4 -0
- package/icons/svgs/crossed-out-eye.svg +5 -0
- package/icons/svgs/default.svg +11 -0
- package/icons/svgs/dots.svg +5 -0
- package/icons/svgs/error.svg +12 -0
- package/icons/svgs/field-close.svg +4 -0
- package/icons/svgs/info.svg +12 -0
- package/icons/svgs/loader.svg +3 -0
- package/icons/svgs/search.svg +4 -0
- package/icons/svgs/success.svg +4 -0
- package/icons/svgs/user.svg +4 -0
- package/icons/svgs/visible-eye.svg +4 -0
- package/icons/svgs/warning.svg +12 -0
- package/index.d.ts +11 -2
- package/index.js +13 -4
- package/index.scss +6 -3
- package/layout/Header/HeaderView.scss +3 -3
- package/layout/Tooltip/TooltipView.js +6 -6
- package/layout/Tooltip/TooltipView.scss +45 -37
- package/list/Grid/GridView.scss +28 -30
- package/nav/Tree/TreeView.scss +9 -10
- package/package.json +56 -56
- package/scss/fonts.scss +6 -0
- package/scss/mixins/button.scss +51 -25
- package/scss/mixins/index.scss +2 -1
- package/scss/mixins/scroll.scss +31 -0
- package/scss/mixins/typography.scss +26 -0
- package/scss/variables/common/colors.scss +87 -67
- package/scss/variables/common/media.scss +2 -0
- package/scss/variables/common/typography.scss +96 -28
- package/scss/variables/components/input.scss +7 -6
- package/scss/variables/index.scss +2 -2
- package/scss/variables/normalize.scss +21 -0
- package/typography/Text/TextView.d.ts +3 -0
- package/typography/Text/TextView.js +46 -0
- package/typography/Text/TextView.scss +16 -0
- package/typography/Title/TitleView.d.ts +3 -0
- package/typography/Title/TitleView.js +50 -0
- package/typography/Title/TitleView.scss +16 -0
- package/content/Collapse/CollapseItemView.d.ts +0 -2
- package/content/Collapse/CollapseItemView.js +0 -65
- package/content/Collapse/CollapseItemView.scss +0 -88
- package/content/Collapse/CollapseView.d.ts +0 -2
- package/content/Icon/IconView.scss +0 -25
- package/icon/fontawesome.d.ts +0 -2
- package/scss/mixins/card.scss +0 -26
- package/scss/variables/components/card.scss +0 -20
|
@@ -23,62 +23,90 @@
|
|
|
23
23
|
--light-gray: #f8f8f8;
|
|
24
24
|
--dark: #6f6b76;
|
|
25
25
|
--light: #9088a1;
|
|
26
|
+
--text-color: #312c3a;
|
|
27
|
+
--background-color: #fff;
|
|
28
|
+
--is-dark: "false";
|
|
29
|
+
--border-color: #eef1f2;
|
|
30
|
+
--border-color-hover: #e5e9eb;
|
|
31
|
+
--placeholder-color: rgba(0, 0, 0, 0.3);
|
|
32
|
+
--placeholder-disabled-color: rgba(0, 0, 0, 0.3);
|
|
33
|
+
--background-disabled-color: #eef1f2;
|
|
34
|
+
--element-background-color: #FFFFFF;
|
|
35
|
+
}
|
|
26
36
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
37
|
+
html[data-theme="dark"] {
|
|
38
|
+
--primary: #8b57ff;
|
|
39
|
+
--primary-dark: #6648a7;
|
|
40
|
+
--primary-light: #ba9bff;
|
|
41
|
+
--secondary: #9ea8db;
|
|
42
|
+
--secondary-dark: #616a95;
|
|
43
|
+
--secondary-light: #bcc3e9;
|
|
44
|
+
--success: #3cf25a;
|
|
45
|
+
--success-dark: #34cc4d;
|
|
46
|
+
--success-light: #74ff8b;
|
|
47
|
+
--danger: #fc6666;
|
|
48
|
+
--danger-dark: #dc5858;
|
|
49
|
+
--danger-light: #ffa1a1;
|
|
50
|
+
--info: #9ae1f1;
|
|
51
|
+
--info-dark: #77c4d6;
|
|
52
|
+
--info-light: #ccf6ff;
|
|
53
|
+
--warning: #ffe457;
|
|
54
|
+
--warning-dark: #ebd251;
|
|
55
|
+
--warning-light: #fff6c8;
|
|
56
|
+
--graphite: #414141;
|
|
57
|
+
--gray-dark: #4e4f57;
|
|
58
|
+
--gray: #5b5c6b;
|
|
59
|
+
--light-gray: #928b9d;
|
|
60
|
+
--dark: #6b6477;
|
|
61
|
+
--light: #b7afc7;
|
|
62
|
+
--text-color: #ffffff;
|
|
63
|
+
--background-color: #323030;
|
|
64
|
+
--is-dark: "true";
|
|
65
|
+
--border-color: #5B5C6B;
|
|
66
|
+
--border-color-hover: #4e4f57;
|
|
67
|
+
--placeholder-color: rgba(255, 255, 255, 0.3);
|
|
68
|
+
--placeholder-disabled-color: rgba(255, 255, 255, 0.1);
|
|
69
|
+
--background-disabled-color: #5b5c6b;
|
|
70
|
+
--element-background-color: #414141;
|
|
53
71
|
}
|
|
54
72
|
|
|
55
73
|
/*
|
|
56
74
|
* SCSS variables implementation
|
|
57
75
|
*/
|
|
58
|
-
$primary: var(--primary)
|
|
59
|
-
$primary-dark: var(--primary-dark)
|
|
60
|
-
$primary-light: var(--primary-light)
|
|
61
|
-
$secondary: var(--secondary)
|
|
62
|
-
$secondary-dark: var(--secondary-dark)
|
|
63
|
-
$secondary-light: var(--secondary-light)
|
|
64
|
-
$success: var(--success)
|
|
65
|
-
$success-dark: var(--success-dark)
|
|
66
|
-
$success-light: var(--success-light)
|
|
67
|
-
$danger: var(--danger)
|
|
68
|
-
$danger-dark: var(--danger-dark)
|
|
69
|
-
$danger-light: var(--danger-light)
|
|
70
|
-
$info: var(--info)
|
|
71
|
-
$info-dark: var(--info-dark)
|
|
72
|
-
$info-light: var(--info-light)
|
|
73
|
-
$warning: var(--warning)
|
|
74
|
-
$warning-dark: var(--warning-dark)
|
|
75
|
-
$warning-light: var(--warning-light)
|
|
76
|
-
$graphite: var(--graphite)
|
|
77
|
-
$gray-dark: var(--gray-dark)
|
|
78
|
-
$gray: var(--gray)
|
|
79
|
-
$light-gray: var(--light-gray)
|
|
80
|
-
$dark: var(--dark)
|
|
81
|
-
$light: var(--light)
|
|
76
|
+
$primary: var(--primary);
|
|
77
|
+
$primary-dark: var(--primary-dark);
|
|
78
|
+
$primary-light: var(--primary-light);
|
|
79
|
+
$secondary: var(--secondary);
|
|
80
|
+
$secondary-dark: var(--secondary-dark);
|
|
81
|
+
$secondary-light: var(--secondary-light);
|
|
82
|
+
$success: var(--success);
|
|
83
|
+
$success-dark: var(--success-dark);
|
|
84
|
+
$success-light: var(--success-light);
|
|
85
|
+
$danger: var(--danger);
|
|
86
|
+
$danger-dark: var(--danger-dark);
|
|
87
|
+
$danger-light: var(--danger-light);
|
|
88
|
+
$info: var(--info);
|
|
89
|
+
$info-dark: var(--info-dark);
|
|
90
|
+
$info-light: var(--info-light);
|
|
91
|
+
$warning: var(--warning);
|
|
92
|
+
$warning-dark: var(--warning-dark);
|
|
93
|
+
$warning-light: var(--warning-light);
|
|
94
|
+
$graphite: var(--graphite);
|
|
95
|
+
$gray-dark: var(--gray-dark);
|
|
96
|
+
$gray: var(--gray);
|
|
97
|
+
$light-gray: var(--light-gray);
|
|
98
|
+
$dark: var(--dark);
|
|
99
|
+
$light: var(--light);
|
|
100
|
+
$text-color: var(--text-color);
|
|
101
|
+
$text-color-revert: var(--text-color-revert);
|
|
102
|
+
$background-color: var(--background-color);
|
|
103
|
+
$is-dark: var(--is-dark);
|
|
104
|
+
$border-color: var(--border-color);
|
|
105
|
+
$border-color-hover: var(--border-color-hover);
|
|
106
|
+
$placeholder-color: var(--placeholder-color);
|
|
107
|
+
$placeholder-disabled-color: var(--placeholder-disabled-color);
|
|
108
|
+
$background-disabled-color: var(--background-disabled-color);
|
|
109
|
+
$element-background-color: var(--element-background-color);
|
|
82
110
|
|
|
83
111
|
/*
|
|
84
112
|
* Common colors
|
|
@@ -91,15 +119,19 @@ $black-10: rgba(#000, 0.1) !default;
|
|
|
91
119
|
$black-4: rgba(#000, 0.04) !default;
|
|
92
120
|
$white: #fff !default;
|
|
93
121
|
|
|
94
|
-
$text-color: #312c3a !default;
|
|
95
122
|
$link-color: #2ba3fb !default;
|
|
96
123
|
|
|
97
|
-
$gradient-
|
|
98
|
-
$gradient-red: linear-gradient(180deg, #EB0155, #FFFA80);
|
|
124
|
+
$gradient-blue: linear-gradient(180deg, #651fff, #ba9bff) !default;
|
|
99
125
|
|
|
100
126
|
$color-themes: () !default;
|
|
101
127
|
$color-themes: map-merge(
|
|
102
128
|
(
|
|
129
|
+
"basic": (
|
|
130
|
+
"color": $gray,
|
|
131
|
+
"color-dark": $gray-dark,
|
|
132
|
+
"color-light": $light-gray,
|
|
133
|
+
"text-color": $text-color,
|
|
134
|
+
),
|
|
103
135
|
"primary": (
|
|
104
136
|
"color": $primary,
|
|
105
137
|
"color-dark": $primary-dark,
|
|
@@ -128,25 +160,13 @@ $color-themes: map-merge(
|
|
|
128
160
|
"color": $warning,
|
|
129
161
|
"color-dark": $warning-dark,
|
|
130
162
|
"color-light": $warning-light,
|
|
131
|
-
"text-color": $
|
|
163
|
+
"text-color": $text-color,
|
|
132
164
|
),
|
|
133
165
|
"info": (
|
|
134
166
|
"color": $info,
|
|
135
167
|
"color-dark": $info-dark,
|
|
136
168
|
"color-light": $info-light,
|
|
137
|
-
"text-color": $
|
|
138
|
-
),
|
|
139
|
-
"light": (
|
|
140
|
-
"color": $light,
|
|
141
|
-
"color-dark": $dark,
|
|
142
|
-
"color-light": $light,
|
|
143
|
-
"text-color": $dark,
|
|
144
|
-
),
|
|
145
|
-
"dark": (
|
|
146
|
-
"color": $dark,
|
|
147
|
-
"color-dark": $dark,
|
|
148
|
-
"color-light": $light,
|
|
149
|
-
"text-color": $white,
|
|
169
|
+
"text-color": $text-color,
|
|
150
170
|
),
|
|
151
171
|
),
|
|
152
172
|
$color-themes
|
|
@@ -4,36 +4,104 @@
|
|
|
4
4
|
|
|
5
5
|
$font-family-nunito: "Nunito", sans-serif;
|
|
6
6
|
|
|
7
|
-
$font-size-xs: 12px;
|
|
8
|
-
$font-size-sm: 14px;
|
|
9
|
-
$font-size-base: 16px;
|
|
10
|
-
$font-size-lg: 18px;
|
|
11
|
-
$font-size-xl: 24px;
|
|
12
|
-
$font-size-2xl: 32px;
|
|
7
|
+
$font-size-xs: 12px !default;
|
|
8
|
+
$font-size-sm: 14px !default;
|
|
9
|
+
$font-size-base: 16px !default;
|
|
10
|
+
$font-size-lg: 18px !default;
|
|
11
|
+
$font-size-xl: 24px !default;
|
|
12
|
+
$font-size-2xl: 32px !default;
|
|
13
13
|
|
|
14
|
-
$line-height-xs: 17px;
|
|
15
|
-
$line-height-sm: 20px;
|
|
16
|
-
$line-height-base: 22px;
|
|
17
|
-
$line-height-lg: 25px;
|
|
18
|
-
$line-height-xl: 34px;
|
|
19
|
-
$line-height-2xl: 45px;
|
|
14
|
+
$line-height-xs: 17px !default;
|
|
15
|
+
$line-height-sm: 20px !default;
|
|
16
|
+
$line-height-base: 22px !default;
|
|
17
|
+
$line-height-lg: 25px !default;
|
|
18
|
+
$line-height-xl: 34px !default;
|
|
19
|
+
$line-height-2xl: 45px !default;
|
|
20
20
|
|
|
21
|
-
$font-weight-sm: 400;
|
|
22
|
-
$font-weight-md: 500;
|
|
23
|
-
$font-weight-lg: 700;
|
|
21
|
+
$font-weight-sm: 400 !default;
|
|
22
|
+
$font-weight-md: 500 !default;
|
|
23
|
+
$font-weight-lg: 700 !default;
|
|
24
24
|
|
|
25
|
+
$title-types: () !default;
|
|
26
|
+
$title-types: map-merge(
|
|
27
|
+
(
|
|
28
|
+
"h1": (
|
|
29
|
+
"font-size": $font-size-2xl,
|
|
30
|
+
"font-weight": $font-weight-lg,
|
|
31
|
+
"line-height": $line-height-2xl,
|
|
32
|
+
"color": $text-color,
|
|
33
|
+
),
|
|
34
|
+
"h2": (
|
|
35
|
+
"font-size": $font-size-xl,
|
|
36
|
+
"font-weight": $font-weight-lg,
|
|
37
|
+
"line-height": $line-height-xl,
|
|
38
|
+
"color": $text-color,
|
|
39
|
+
),
|
|
40
|
+
"h3": (
|
|
41
|
+
"font-size": $font-size-lg,
|
|
42
|
+
"font-weight": $font-weight-lg,
|
|
43
|
+
"line-height": $line-height-lg,
|
|
44
|
+
"color": $text-color,
|
|
45
|
+
),
|
|
46
|
+
"h4": (
|
|
47
|
+
"font-size": $font-size-base,
|
|
48
|
+
"font-weight": $font-weight-lg,
|
|
49
|
+
"line-height": $line-height-base,
|
|
50
|
+
"color": $text-color,
|
|
51
|
+
),
|
|
52
|
+
"h5": (
|
|
53
|
+
"font-size": $font-size-sm,
|
|
54
|
+
"font-weight": $font-weight-md,
|
|
55
|
+
"line-height": $line-height-sm,
|
|
56
|
+
"color": $text-color,
|
|
57
|
+
),
|
|
58
|
+
"h6": (
|
|
59
|
+
"font-size": $font-size-xs,
|
|
60
|
+
"font-weight": $font-weight-md,
|
|
61
|
+
"line-height": $line-height-xs,
|
|
62
|
+
"color": $text-color,
|
|
63
|
+
),
|
|
64
|
+
"subtitle": (
|
|
65
|
+
"font-size": $font-size-2xl,
|
|
66
|
+
"font-weight": $font-weight-md,
|
|
67
|
+
"line-height": $line-height-2xl,
|
|
68
|
+
"color": $text-color,
|
|
69
|
+
),
|
|
70
|
+
),
|
|
71
|
+
$title-types
|
|
72
|
+
);
|
|
25
73
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
$
|
|
31
|
-
$
|
|
32
|
-
|
|
33
|
-
$
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
$
|
|
74
|
+
$text-types: () !default;
|
|
75
|
+
$text-types: map-merge(
|
|
76
|
+
(
|
|
77
|
+
"body": (
|
|
78
|
+
"font-size": $font-size-base,
|
|
79
|
+
"font-weight": $font-weight-sm,
|
|
80
|
+
"line-height": $line-height-base,
|
|
81
|
+
"color": $text-color,
|
|
82
|
+
),
|
|
83
|
+
"span": (
|
|
84
|
+
"font-size": $font-size-base,
|
|
85
|
+
"font-weight": $font-weight-sm,
|
|
86
|
+
"line-height": $line-height-base,
|
|
87
|
+
"color": $text-color,
|
|
88
|
+
),
|
|
89
|
+
"boldSpan": (
|
|
90
|
+
"font-size": $font-size-base,
|
|
91
|
+
"font-weight": $font-weight-lg,
|
|
92
|
+
"line-height": $line-height-base,
|
|
93
|
+
"color": $text-color,
|
|
94
|
+
),
|
|
95
|
+
),
|
|
96
|
+
$text-types
|
|
97
|
+
);
|
|
38
98
|
|
|
39
|
-
$
|
|
99
|
+
$typography-colors: (
|
|
100
|
+
"text-color": $text-color,
|
|
101
|
+
"primary": $primary,
|
|
102
|
+
"secondary": $secondary,
|
|
103
|
+
"success": $success,
|
|
104
|
+
"danger": $danger,
|
|
105
|
+
"warning": $warning,
|
|
106
|
+
"info": $info,
|
|
107
|
+
);
|
|
@@ -1,3 +1,9 @@
|
|
|
1
|
+
$input-height-sm: 34px;
|
|
2
|
+
$input-height-md: 46px;
|
|
3
|
+
$input-height-lg: 56px;
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
//remove after ready all inputs
|
|
1
7
|
//Small
|
|
2
8
|
$input-label-margin-bottom-sm: 4px;
|
|
3
9
|
|
|
@@ -52,15 +58,10 @@ $input-message-margin-top-lg: $input-message-margin-top-sm;
|
|
|
52
58
|
$input-message-icon-size-lg: $input-message-icon-size-sm;
|
|
53
59
|
$input-message-icon-margin-right-lg: $input-message-icon-margin-right-sm;
|
|
54
60
|
|
|
55
|
-
|
|
56
|
-
$input-height-sm: 28px !default;
|
|
57
|
-
$input-height-md: 36px !default;
|
|
58
|
-
$input-height-lg: 46px !default;
|
|
59
|
-
|
|
60
61
|
$input-border: 1px solid $border-default !default;
|
|
61
62
|
$input-border-radius: 4px !default;
|
|
62
63
|
|
|
63
64
|
$input-padding-y: 0 !default;
|
|
64
65
|
$input-padding-x: 8px !default;
|
|
65
66
|
$input-addon-padding: 0.6rem !default;
|
|
66
|
-
$input-text-padding: 0.4rem !default;
|
|
67
|
+
$input-text-padding: 0.4rem !default;
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
+
@import 'normalize.scss';
|
|
1
2
|
@import 'common/colors';
|
|
3
|
+
@import 'common/media';
|
|
2
4
|
@import 'common/typography';
|
|
3
|
-
@import 'common/spacing';
|
|
4
5
|
@import 'common/radiuses';
|
|
5
6
|
@import 'common/old-variables';
|
|
6
7
|
|
|
7
8
|
@import 'components/button';
|
|
8
9
|
@import 'components/calendar';
|
|
9
|
-
@import 'components/card';
|
|
10
10
|
@import 'components/icon';
|
|
11
11
|
@import 'components/input';
|
|
12
12
|
@import 'components/ratefield';
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
@import-normalize;
|
|
2
|
+
|
|
3
|
+
* {
|
|
4
|
+
margin: 0;
|
|
5
|
+
padding: 0;
|
|
6
|
+
box-sizing: border-box;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
a {
|
|
10
|
+
text-decoration: none;
|
|
11
|
+
color: inherit;
|
|
12
|
+
font-family: inherit;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
button {
|
|
16
|
+
font-family: inherit;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
input {
|
|
20
|
+
outline: none;
|
|
21
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
exports.__esModule = true;
|
|
26
|
+
var React = __importStar(require("react"));
|
|
27
|
+
var hooks_1 = require("@steroidsjs/core/hooks");
|
|
28
|
+
var TYPE_MAPPING = {
|
|
29
|
+
body: 'p',
|
|
30
|
+
span: 'span',
|
|
31
|
+
boldSpan: 'span'
|
|
32
|
+
};
|
|
33
|
+
function TextView(props) {
|
|
34
|
+
var bem = (0, hooks_1.useBem)('TextView');
|
|
35
|
+
var tag = props.tag || TYPE_MAPPING[props.type || ''] || 'p';
|
|
36
|
+
return (React.createElement(tag, {
|
|
37
|
+
className: bem(bem.block({
|
|
38
|
+
type: props.type,
|
|
39
|
+
color: props.color
|
|
40
|
+
}), props.className),
|
|
41
|
+
style: props.style
|
|
42
|
+
}, React.createElement(React.Fragment, null,
|
|
43
|
+
props.content,
|
|
44
|
+
props.children)));
|
|
45
|
+
}
|
|
46
|
+
exports["default"] = TextView;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
.TextView {
|
|
2
|
+
margin-bottom: 1em;
|
|
3
|
+
font-family: $font-family-nunito;
|
|
4
|
+
|
|
5
|
+
@each $typeName, $typeMap in $text-types {
|
|
6
|
+
&_type_#{$typeName} {
|
|
7
|
+
@include typography-type($typeMap);
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
@each $colorName, $color in $typography-colors {
|
|
12
|
+
&_color_#{$colorName} {
|
|
13
|
+
color: $color;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
+
if (mod && mod.__esModule) return mod;
|
|
20
|
+
var result = {};
|
|
21
|
+
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
+
__setModuleDefault(result, mod);
|
|
23
|
+
return result;
|
|
24
|
+
};
|
|
25
|
+
exports.__esModule = true;
|
|
26
|
+
var React = __importStar(require("react"));
|
|
27
|
+
var hooks_1 = require("@steroidsjs/core/hooks");
|
|
28
|
+
var TYPE_MAPPING = {
|
|
29
|
+
h1: 'h1',
|
|
30
|
+
h2: 'h2',
|
|
31
|
+
h3: 'h3',
|
|
32
|
+
h4: 'h4',
|
|
33
|
+
h5: 'h5',
|
|
34
|
+
h6: 'h6',
|
|
35
|
+
subtitle: 'h6'
|
|
36
|
+
};
|
|
37
|
+
function TitleView(props) {
|
|
38
|
+
var bem = (0, hooks_1.useBem)('TitleView');
|
|
39
|
+
var tag = props.tag || TYPE_MAPPING[props.type || ''] || 'h2';
|
|
40
|
+
return (React.createElement(tag, {
|
|
41
|
+
className: bem(bem.block({
|
|
42
|
+
type: props.type,
|
|
43
|
+
color: props.color
|
|
44
|
+
}), props.className),
|
|
45
|
+
style: props.style
|
|
46
|
+
}, React.createElement(React.Fragment, null,
|
|
47
|
+
props.content,
|
|
48
|
+
props.children)));
|
|
49
|
+
}
|
|
50
|
+
exports["default"] = TitleView;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
.TitleView {
|
|
2
|
+
margin-bottom: 1em;
|
|
3
|
+
font-family: $font-family-nunito;
|
|
4
|
+
|
|
5
|
+
@each $typeName, $typeMap in $title-types {
|
|
6
|
+
&_type_#{$typeName} {
|
|
7
|
+
@include typography-type($typeMap);
|
|
8
|
+
}
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
@each $colorName, $color in $typography-colors {
|
|
12
|
+
&_color_#{$colorName} {
|
|
13
|
+
color: $color;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
}
|
|
@@ -1,65 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
-
}) : function(o, v) {
|
|
16
|
-
o["default"] = v;
|
|
17
|
-
});
|
|
18
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
19
|
-
if (mod && mod.__esModule) return mod;
|
|
20
|
-
var result = {};
|
|
21
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
22
|
-
__setModuleDefault(result, mod);
|
|
23
|
-
return result;
|
|
24
|
-
};
|
|
25
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
26
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
27
|
-
};
|
|
28
|
-
exports.__esModule = true;
|
|
29
|
-
var React = __importStar(require("react"));
|
|
30
|
-
var Icon_1 = __importDefault(require("@steroidsjs/core/ui/content/Icon"));
|
|
31
|
-
var hooks_1 = require("@steroidsjs/core/hooks");
|
|
32
|
-
function CollapseItemView(props) {
|
|
33
|
-
var bem = (0, hooks_1.useBem)('CollapseItemView');
|
|
34
|
-
React.useEffect(function () {
|
|
35
|
-
if (props.isAccordion) {
|
|
36
|
-
props.toggleAccordion(props.activeKey - 1);
|
|
37
|
-
}
|
|
38
|
-
else {
|
|
39
|
-
props.toggleCollapse(props.activeKey - 1);
|
|
40
|
-
}
|
|
41
|
-
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
42
|
-
}, [props.activeKey]);
|
|
43
|
-
return (React.createElement("div", { className: bem(bem.block({
|
|
44
|
-
disable: props.disabled,
|
|
45
|
-
borderless: props.borderless
|
|
46
|
-
}), props.className), style: props.style },
|
|
47
|
-
React.createElement("div", { className: bem.element('header-container', { revert: props.iconPosition === 'left' }), onClick: !props.disabled
|
|
48
|
-
? function () {
|
|
49
|
-
// eslint-disable-next-line no-unused-expressions
|
|
50
|
-
props.isAccordion
|
|
51
|
-
? props.toggleAccordion(props.childIndex)
|
|
52
|
-
: props.toggleCollapse(props.childIndex);
|
|
53
|
-
}
|
|
54
|
-
: null },
|
|
55
|
-
React.createElement("div", { className: bem.element('title-container') },
|
|
56
|
-
React.createElement("p", null, props.title)),
|
|
57
|
-
React.createElement("div", { className: bem.element('icon-wrapper', { not_visible: !props.showIcon }) }, props.icon
|
|
58
|
-
? (typeof props.icon === 'string' ? React.createElement(Icon_1["default"], { name: props.icon }) : props.icon)
|
|
59
|
-
: (React.createElement(Icon_1["default"], { className: bem.element('icon', {
|
|
60
|
-
active: !props.disabled && props.isShowMore,
|
|
61
|
-
disable_cursor: !props.showIcon
|
|
62
|
-
}), name: "chevron-down" })))),
|
|
63
|
-
React.createElement("div", { className: bem.element('content', { visible: !props.disabled && props.isShowMore }) }, props.children)));
|
|
64
|
-
}
|
|
65
|
-
exports["default"] = CollapseItemView;
|