@salutejs/plasma-sb-utils 0.231.0-next-sbcom.0 → 0.231.0

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 (94) hide show
  1. package/lib/components/Attach/Attach.d.ts +248 -0
  2. package/lib/components/Attach/Attach.js +35 -0
  3. package/lib/components/Attach/Attach.js.map +1 -0
  4. package/lib/components/Attach/fixtures.d.ts +6 -0
  5. package/lib/components/Attach/fixtures.js +7 -0
  6. package/lib/components/Attach/fixtures.js.map +1 -0
  7. package/lib/components/Attach/index.d.ts +1 -0
  8. package/lib/components/Attach/index.js +2 -0
  9. package/lib/components/Attach/index.js.map +1 -0
  10. package/lib/components/Attach/meta.d.ts +243 -0
  11. package/lib/components/Attach/meta.js +150 -0
  12. package/lib/components/Attach/meta.js.map +1 -0
  13. package/lib/components/Attach/stories.d.ts +1 -0
  14. package/lib/components/Attach/stories.js +71 -0
  15. package/lib/components/Attach/stories.js.map +1 -0
  16. package/lib/components/Badge/Badge.d.ts +119 -0
  17. package/lib/components/Badge/Badge.js +40 -0
  18. package/lib/components/Badge/Badge.js.map +1 -0
  19. package/lib/components/Badge/fixtures.d.ts +3 -0
  20. package/lib/components/Badge/fixtures.js +7 -0
  21. package/lib/components/Badge/fixtures.js.map +1 -0
  22. package/lib/components/Badge/index.d.ts +1 -0
  23. package/lib/components/Badge/index.js +2 -0
  24. package/lib/components/Badge/index.js.map +1 -0
  25. package/lib/components/Badge/meta.d.ts +114 -0
  26. package/lib/components/Badge/meta.js +67 -0
  27. package/lib/components/Badge/meta.js.map +1 -0
  28. package/lib/components/Badge/stories.d.ts +1 -0
  29. package/lib/components/Badge/stories.js +34 -0
  30. package/lib/components/Badge/stories.js.map +1 -0
  31. package/lib/components/Button/Button.d.ts +50 -4
  32. package/lib/components/Button/meta.d.ts +50 -4
  33. package/lib/components/Button/meta.js +25 -6
  34. package/lib/components/Button/meta.js.map +1 -1
  35. package/lib/components/Chip/meta.js +1 -1
  36. package/lib/components/Chip/meta.js.map +1 -1
  37. package/lib/components/CodeField/CodeField.d.ts +156 -0
  38. package/lib/components/CodeField/CodeField.js +40 -0
  39. package/lib/components/CodeField/CodeField.js.map +1 -0
  40. package/lib/components/CodeField/fixtures.d.ts +6 -0
  41. package/lib/components/CodeField/fixtures.js +7 -0
  42. package/lib/components/CodeField/fixtures.js.map +1 -0
  43. package/lib/components/CodeField/index.d.ts +1 -0
  44. package/lib/components/CodeField/index.js +2 -0
  45. package/lib/components/CodeField/index.js.map +1 -0
  46. package/lib/components/CodeField/meta.d.ts +151 -0
  47. package/lib/components/CodeField/meta.js +84 -0
  48. package/lib/components/CodeField/meta.js.map +1 -0
  49. package/lib/components/CodeField/stories.d.ts +1 -0
  50. package/lib/components/CodeField/stories.js +38 -0
  51. package/lib/components/CodeField/stories.js.map +1 -0
  52. package/lib/components/CodeInput/CodeInput.d.ts +147 -0
  53. package/lib/components/CodeInput/CodeInput.js +40 -0
  54. package/lib/components/CodeInput/CodeInput.js.map +1 -0
  55. package/lib/components/CodeInput/fixtures.d.ts +5 -0
  56. package/lib/components/CodeInput/fixtures.js +6 -0
  57. package/lib/components/CodeInput/fixtures.js.map +1 -0
  58. package/lib/components/CodeInput/index.d.ts +1 -0
  59. package/lib/components/CodeInput/index.js +2 -0
  60. package/lib/components/CodeInput/index.js.map +1 -0
  61. package/lib/components/CodeInput/meta.d.ts +142 -0
  62. package/lib/components/CodeInput/meta.js +80 -0
  63. package/lib/components/CodeInput/meta.js.map +1 -0
  64. package/lib/components/CodeInput/stories.d.ts +1 -0
  65. package/lib/components/CodeInput/stories.js +38 -0
  66. package/lib/components/CodeInput/stories.js.map +1 -0
  67. package/lib/components/DatePicker/DatePicker.d.ts +443 -2
  68. package/lib/components/DatePicker/meta.d.ts +443 -2
  69. package/lib/components/DatePicker/meta.js +176 -154
  70. package/lib/components/DatePicker/meta.js.map +1 -1
  71. package/lib/components/DatePicker/stories.js +3 -0
  72. package/lib/components/DatePicker/stories.js.map +1 -1
  73. package/lib/components/DateTimePicker/stories.d.ts +1 -1
  74. package/lib/components/DateTimePicker/stories.js +2 -2
  75. package/lib/components/DateTimePicker/stories.js.map +1 -1
  76. package/lib/components/Range/stories.js +2 -0
  77. package/lib/components/Range/stories.js.map +1 -1
  78. package/lib/components/Steps/Steps.js +1 -4
  79. package/lib/components/Steps/Steps.js.map +1 -1
  80. package/lib/components/TextField/TextField.d.ts +143 -0
  81. package/lib/components/TextField/meta.d.ts +143 -0
  82. package/lib/components/TextField/meta.js +69 -45
  83. package/lib/components/TextField/meta.js.map +1 -1
  84. package/lib/components/TimePicker/TimePicker.d.ts +20 -0
  85. package/lib/components/TimePicker/fixtures.d.ts +1 -0
  86. package/lib/components/TimePicker/fixtures.js +1 -0
  87. package/lib/components/TimePicker/fixtures.js.map +1 -1
  88. package/lib/components/TimePicker/meta.d.ts +20 -0
  89. package/lib/components/TimePicker/meta.js +10 -2
  90. package/lib/components/TimePicker/meta.js.map +1 -1
  91. package/lib/components/index.d.ts +4 -0
  92. package/lib/components/index.js +4 -0
  93. package/lib/components/index.js.map +1 -1
  94. package/package.json +4 -4
@@ -0,0 +1,248 @@
1
+ type CreateStoriesProps = {
2
+ component: any;
3
+ componentConfig: any;
4
+ title?: string;
5
+ disablePropsList?: string[];
6
+ defaultArgs?: {};
7
+ additionalArgTypes?: {};
8
+ };
9
+ export declare const getAttachStories: (config: CreateStoriesProps) => {
10
+ meta: {
11
+ title: string;
12
+ decorators: import("@storybook/react").Decorator[];
13
+ component: any;
14
+ parameters: {
15
+ controls: {
16
+ disableSaveFromUI: boolean;
17
+ };
18
+ };
19
+ args: {
20
+ controlled: boolean;
21
+ size: string;
22
+ view: string;
23
+ width: string;
24
+ fileFormat: string;
25
+ multiple: boolean;
26
+ flow: string;
27
+ hasAttachment: boolean;
28
+ hideButtonOnAttach: boolean;
29
+ buttonType: string;
30
+ buttonText: string;
31
+ buttonValue: string;
32
+ enableContentLeft: boolean;
33
+ enableContentRight: boolean;
34
+ helperTextView: string;
35
+ helperText: string;
36
+ placement: string;
37
+ trigger: string;
38
+ listWidth: string;
39
+ closeOnOverlayClick: boolean;
40
+ };
41
+ argTypes: {
42
+ controlled: {
43
+ control: {
44
+ type: string;
45
+ };
46
+ table: {
47
+ category: string;
48
+ };
49
+ };
50
+ view: {
51
+ options: any;
52
+ control: {
53
+ type: string;
54
+ };
55
+ table: {
56
+ category: string;
57
+ };
58
+ };
59
+ size: {
60
+ options: any;
61
+ control: {
62
+ type: string;
63
+ };
64
+ table: {
65
+ category: string;
66
+ };
67
+ };
68
+ helperTextView: {
69
+ options: string[];
70
+ control: {
71
+ type: string;
72
+ };
73
+ table: {
74
+ category: string;
75
+ };
76
+ };
77
+ buttonType: {
78
+ options: string[];
79
+ control: {
80
+ type: string;
81
+ };
82
+ table: {
83
+ category: string;
84
+ };
85
+ };
86
+ disabled: {
87
+ control: {
88
+ type: string;
89
+ };
90
+ table: {
91
+ category: string;
92
+ };
93
+ };
94
+ buttonText: {
95
+ control: {
96
+ type: string;
97
+ };
98
+ if: {
99
+ arg: string;
100
+ eq: string;
101
+ };
102
+ table: {
103
+ category: string;
104
+ };
105
+ };
106
+ buttonValue: {
107
+ control: {
108
+ type: string;
109
+ };
110
+ if: {
111
+ arg: string;
112
+ eq: string;
113
+ };
114
+ table: {
115
+ category: string;
116
+ };
117
+ };
118
+ enableContentLeft: {
119
+ control: {
120
+ type: string;
121
+ };
122
+ if: {
123
+ arg: string;
124
+ eq: string;
125
+ };
126
+ table: {
127
+ category: string;
128
+ };
129
+ };
130
+ enableContentRight: {
131
+ control: {
132
+ type: string;
133
+ };
134
+ if: {
135
+ arg: string;
136
+ eq: string;
137
+ };
138
+ table: {
139
+ category: string;
140
+ };
141
+ };
142
+ width: {
143
+ control: {
144
+ type: string;
145
+ };
146
+ table: {
147
+ category: string;
148
+ };
149
+ };
150
+ helperText: {
151
+ control: {
152
+ type: string;
153
+ };
154
+ table: {
155
+ category: string;
156
+ };
157
+ };
158
+ fileFormat: {
159
+ options: string[];
160
+ control: {
161
+ type: string;
162
+ };
163
+ table: {
164
+ category: string;
165
+ };
166
+ };
167
+ multiple: {
168
+ control: {
169
+ type: string;
170
+ };
171
+ table: {
172
+ category: string;
173
+ };
174
+ };
175
+ flow: {
176
+ options: string[];
177
+ control: {
178
+ type: string;
179
+ };
180
+ table: {
181
+ category: string;
182
+ };
183
+ };
184
+ hasAttachment: {
185
+ control: {
186
+ type: string;
187
+ };
188
+ if: {
189
+ arg: string;
190
+ truthy: boolean;
191
+ };
192
+ table: {
193
+ category: string;
194
+ };
195
+ };
196
+ hideButtonOnAttach: {
197
+ control: {
198
+ type: string;
199
+ };
200
+ table: {
201
+ category: string;
202
+ };
203
+ };
204
+ placement: {
205
+ options: string[];
206
+ control: {
207
+ type: string;
208
+ };
209
+ table: {
210
+ category: string;
211
+ };
212
+ };
213
+ trigger: {
214
+ options: string[];
215
+ control: {
216
+ type: string;
217
+ };
218
+ table: {
219
+ category: string;
220
+ };
221
+ };
222
+ closeOnOverlayClick: {
223
+ control: {
224
+ type: string;
225
+ };
226
+ if: {
227
+ arg: string;
228
+ truthy: boolean;
229
+ };
230
+ table: {
231
+ category: string;
232
+ };
233
+ };
234
+ listWidth: {
235
+ control: {
236
+ type: string;
237
+ };
238
+ table: {
239
+ category: string;
240
+ };
241
+ };
242
+ };
243
+ };
244
+ Default: {
245
+ render: (args: any) => JSX.Element;
246
+ };
247
+ };
248
+ export {};
@@ -0,0 +1,35 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
12
+ var __rest = (this && this.__rest) || function (s, e) {
13
+ var t = {};
14
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
15
+ t[p] = s[p];
16
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
17
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
18
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
19
+ t[p[i]] = s[p[i]];
20
+ }
21
+ return t;
22
+ };
23
+ import React from 'react';
24
+ import { getConfigVariations } from '../../helpers';
25
+ import { createMeta } from './meta';
26
+ import { createDefaultStory } from './stories';
27
+ export var getAttachStories = function (config) {
28
+ var component = config.component, componentConfig = config.componentConfig, rest = __rest(config, ["component", "componentConfig"]);
29
+ var componentConfigVariations = getConfigVariations(componentConfig);
30
+ var meta = createMeta(__assign({ component: component, componentConfig: componentConfigVariations }, rest));
31
+ var DefaultStoryComponent = createDefaultStory(component);
32
+ var Default = { render: function (args) { return React.createElement(DefaultStoryComponent, __assign({}, args)); } };
33
+ return { meta: meta, Default: Default };
34
+ };
35
+ //# sourceMappingURL=Attach.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"Attach.js","sourceRoot":"","sources":["../../../src/components/Attach/Attach.tsx"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,mBAAmB,EAAE,MAAM,eAAe,CAAC;AAEpD,OAAO,EAAE,UAAU,EAAE,MAAM,QAAQ,CAAC;AACpC,OAAO,EAAE,kBAAkB,EAAE,MAAM,WAAW,CAAC;AAW/C,MAAM,CAAC,IAAM,gBAAgB,GAAG,UAAC,MAA0B;IAC/C,IAAA,SAAS,GAA+B,MAAM,UAArC,EAAE,eAAe,GAAc,MAAM,gBAApB,EAAK,IAAI,UAAK,MAAM,EAAhD,gCAAuC,CAAF,CAAY;IACvD,IAAM,yBAAyB,GAAG,mBAAmB,CAAC,eAAe,CAAC,CAAC;IACvE,IAAM,IAAI,GAAG,UAAU,YAAG,SAAS,WAAA,EAAE,eAAe,EAAE,yBAAyB,IAAK,IAAI,EAAG,CAAC;IAC5F,IAAM,qBAAqB,GAAG,kBAAkB,CAAC,SAAS,CAAC,CAAC;IAC5D,IAAM,OAAO,GAAG,EAAE,MAAM,EAAE,UAAC,IAAS,IAAK,OAAA,oBAAC,qBAAqB,eAAK,IAAI,EAAI,EAAnC,CAAmC,EAAE,CAAC;IAC/E,OAAO,EAAE,IAAI,MAAA,EAAE,OAAO,SAAA,EAAE,CAAC;AAC7B,CAAC,CAAC"}
@@ -0,0 +1,6 @@
1
+ export declare const flowOptions: string[];
2
+ export declare const fileFormatOptions: string[];
3
+ export declare const placements: string[];
4
+ export declare const triggers: string[];
5
+ export declare const buttonTypeVariants: string[];
6
+ export declare const helperTextViews: string[];
@@ -0,0 +1,7 @@
1
+ export var flowOptions = ['horizontal', 'vertical', 'auto'];
2
+ export var fileFormatOptions = ['all', '.doc', '.xls', '.pdf', '.csv', '.txt'];
3
+ export var placements = ['auto', 'top', 'right', 'bottom', 'left'];
4
+ export var triggers = ['click', 'hover'];
5
+ export var buttonTypeVariants = ['button', 'iconButton'];
6
+ export var helperTextViews = ['default', 'negative'];
7
+ //# sourceMappingURL=fixtures.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fixtures.js","sourceRoot":"","sources":["../../../src/components/Attach/fixtures.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,IAAM,WAAW,GAAG,CAAC,YAAY,EAAE,UAAU,EAAE,MAAM,CAAC,CAAC;AAC9D,MAAM,CAAC,IAAM,iBAAiB,GAAG,CAAC,KAAK,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,CAAC;AACjF,MAAM,CAAC,IAAM,UAAU,GAAG,CAAC,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,CAAC,CAAC;AACrE,MAAM,CAAC,IAAM,QAAQ,GAAG,CAAC,OAAO,EAAE,OAAO,CAAC,CAAC;AAC3C,MAAM,CAAC,IAAM,kBAAkB,GAAG,CAAC,QAAQ,EAAE,YAAY,CAAC,CAAC;AAC3D,MAAM,CAAC,IAAM,eAAe,GAAG,CAAC,SAAS,EAAE,UAAU,CAAC,CAAC"}
@@ -0,0 +1 @@
1
+ export * from './Attach';
@@ -0,0 +1,2 @@
1
+ export * from './Attach';
2
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/components/Attach/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC"}
@@ -0,0 +1,243 @@
1
+ type CreateMetaProps = {
2
+ component: any;
3
+ componentConfig: any;
4
+ title?: string;
5
+ defaultArgs?: {};
6
+ additionalArgTypes?: {};
7
+ disablePropsList?: string[];
8
+ };
9
+ export declare const createMeta: ({ component, componentConfig, title, defaultArgs, additionalArgTypes, disablePropsList, }: CreateMetaProps) => {
10
+ title: string;
11
+ decorators: import("@storybook/react").Decorator[];
12
+ component: any;
13
+ parameters: {
14
+ controls: {
15
+ disableSaveFromUI: boolean;
16
+ };
17
+ };
18
+ args: {
19
+ controlled: boolean;
20
+ size: string;
21
+ view: string;
22
+ width: string;
23
+ fileFormat: string;
24
+ multiple: boolean;
25
+ flow: string;
26
+ hasAttachment: boolean;
27
+ hideButtonOnAttach: boolean;
28
+ buttonType: string;
29
+ buttonText: string;
30
+ buttonValue: string;
31
+ enableContentLeft: boolean;
32
+ enableContentRight: boolean;
33
+ helperTextView: string;
34
+ helperText: string;
35
+ placement: string;
36
+ trigger: string;
37
+ listWidth: string;
38
+ closeOnOverlayClick: boolean;
39
+ };
40
+ argTypes: {
41
+ controlled: {
42
+ control: {
43
+ type: string;
44
+ };
45
+ table: {
46
+ category: string;
47
+ };
48
+ };
49
+ view: {
50
+ options: any;
51
+ control: {
52
+ type: string;
53
+ };
54
+ table: {
55
+ category: string;
56
+ };
57
+ };
58
+ size: {
59
+ options: any;
60
+ control: {
61
+ type: string;
62
+ };
63
+ table: {
64
+ category: string;
65
+ };
66
+ };
67
+ helperTextView: {
68
+ options: string[];
69
+ control: {
70
+ type: string;
71
+ };
72
+ table: {
73
+ category: string;
74
+ };
75
+ };
76
+ buttonType: {
77
+ options: string[];
78
+ control: {
79
+ type: string;
80
+ };
81
+ table: {
82
+ category: string;
83
+ };
84
+ };
85
+ disabled: {
86
+ control: {
87
+ type: string;
88
+ };
89
+ table: {
90
+ category: string;
91
+ };
92
+ };
93
+ buttonText: {
94
+ control: {
95
+ type: string;
96
+ };
97
+ if: {
98
+ arg: string;
99
+ eq: string;
100
+ };
101
+ table: {
102
+ category: string;
103
+ };
104
+ };
105
+ buttonValue: {
106
+ control: {
107
+ type: string;
108
+ };
109
+ if: {
110
+ arg: string;
111
+ eq: string;
112
+ };
113
+ table: {
114
+ category: string;
115
+ };
116
+ };
117
+ enableContentLeft: {
118
+ control: {
119
+ type: string;
120
+ };
121
+ if: {
122
+ arg: string;
123
+ eq: string;
124
+ };
125
+ table: {
126
+ category: string;
127
+ };
128
+ };
129
+ enableContentRight: {
130
+ control: {
131
+ type: string;
132
+ };
133
+ if: {
134
+ arg: string;
135
+ eq: string;
136
+ };
137
+ table: {
138
+ category: string;
139
+ };
140
+ };
141
+ width: {
142
+ control: {
143
+ type: string;
144
+ };
145
+ table: {
146
+ category: string;
147
+ };
148
+ };
149
+ helperText: {
150
+ control: {
151
+ type: string;
152
+ };
153
+ table: {
154
+ category: string;
155
+ };
156
+ };
157
+ fileFormat: {
158
+ options: string[];
159
+ control: {
160
+ type: string;
161
+ };
162
+ table: {
163
+ category: string;
164
+ };
165
+ };
166
+ multiple: {
167
+ control: {
168
+ type: string;
169
+ };
170
+ table: {
171
+ category: string;
172
+ };
173
+ };
174
+ flow: {
175
+ options: string[];
176
+ control: {
177
+ type: string;
178
+ };
179
+ table: {
180
+ category: string;
181
+ };
182
+ };
183
+ hasAttachment: {
184
+ control: {
185
+ type: string;
186
+ };
187
+ if: {
188
+ arg: string;
189
+ truthy: boolean;
190
+ };
191
+ table: {
192
+ category: string;
193
+ };
194
+ };
195
+ hideButtonOnAttach: {
196
+ control: {
197
+ type: string;
198
+ };
199
+ table: {
200
+ category: string;
201
+ };
202
+ };
203
+ placement: {
204
+ options: string[];
205
+ control: {
206
+ type: string;
207
+ };
208
+ table: {
209
+ category: string;
210
+ };
211
+ };
212
+ trigger: {
213
+ options: string[];
214
+ control: {
215
+ type: string;
216
+ };
217
+ table: {
218
+ category: string;
219
+ };
220
+ };
221
+ closeOnOverlayClick: {
222
+ control: {
223
+ type: string;
224
+ };
225
+ if: {
226
+ arg: string;
227
+ truthy: boolean;
228
+ };
229
+ table: {
230
+ category: string;
231
+ };
232
+ };
233
+ listWidth: {
234
+ control: {
235
+ type: string;
236
+ };
237
+ table: {
238
+ category: string;
239
+ };
240
+ };
241
+ };
242
+ };
243
+ export {};