playbook_ui 12.32.0 → 12.33.0.pre.alpha.PLAY905reactionbuttons979

Sign up to get free protection for your applications and to get access to all the features.
Files changed (65) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/index.js +1 -1
  3. data/app/pb_kits/playbook/pb_background/_background.tsx +10 -1
  4. data/app/pb_kits/playbook/pb_background/background.html.erb +2 -1
  5. data/app/pb_kits/playbook/pb_background/background.rb +4 -2
  6. data/app/pb_kits/playbook/pb_body/_body_mixins.scss +1 -0
  7. data/app/pb_kits/playbook/pb_button/_button.scss +33 -0
  8. data/app/pb_kits/playbook/pb_button/_button.tsx +65 -26
  9. data/app/pb_kits/playbook/pb_button/_button_mixins.scss +6 -6
  10. data/app/pb_kits/playbook/pb_button/button.html.erb +13 -0
  11. data/app/pb_kits/playbook/pb_button/button.rb +13 -2
  12. data/app/pb_kits/playbook/pb_button/docs/_button_reaction.html.erb +3 -0
  13. data/app/pb_kits/playbook/pb_button/docs/_button_reaction.jsx +38 -0
  14. data/app/pb_kits/playbook/pb_button/docs/example.yml +2 -0
  15. data/app/pb_kits/playbook/pb_button/docs/index.js +2 -1
  16. data/app/pb_kits/playbook/pb_circle_icon_button/_circle_icon_button.scss +1 -1
  17. data/app/pb_kits/playbook/pb_date/_date.tsx +7 -8
  18. data/app/pb_kits/playbook/pb_date/docs/_date_alignment.jsx +2 -2
  19. data/app/pb_kits/playbook/pb_date/docs/_date_default.jsx +4 -4
  20. data/app/pb_kits/playbook/pb_date/docs/_date_unstyled.jsx +2 -2
  21. data/app/pb_kits/playbook/pb_date/docs/_date_variants.jsx +5 -5
  22. data/app/pb_kits/playbook/pb_date_range_inline/_date_range_inline.tsx +45 -31
  23. data/app/pb_kits/playbook/pb_date_range_stacked/_date_range_stacked.tsx +5 -3
  24. data/app/pb_kits/playbook/pb_date_stacked/_date_stacked.tsx +24 -21
  25. data/app/pb_kits/playbook/pb_date_time/_date_time.tsx +1 -1
  26. data/app/pb_kits/playbook/pb_date_time/dateTime.test.js +1 -1
  27. data/app/pb_kits/playbook/pb_date_time_stacked/_date_time_stacked.tsx +2 -2
  28. data/app/pb_kits/playbook/pb_date_time_stacked/date_time_stacked.test.js +1 -1
  29. data/app/pb_kits/playbook/pb_date_year_stacked/_date_year_stacked.tsx +6 -8
  30. data/app/pb_kits/playbook/pb_dialog/_dialog.scss +321 -316
  31. data/app/pb_kits/playbook/pb_dialog/_dialog.tsx +12 -9
  32. data/app/pb_kits/playbook/pb_dialog/dialog.html.erb +8 -8
  33. data/app/pb_kits/playbook/pb_dialog/dialogHelper.js +16 -15
  34. data/app/pb_kits/playbook/pb_icon/_icon.tsx +4 -2
  35. data/app/pb_kits/playbook/pb_icon/docs/_icon_fa_kit.html.erb +1 -0
  36. data/app/pb_kits/playbook/pb_icon/docs/_icon_fa_kit.jsx +21 -0
  37. data/app/pb_kits/playbook/pb_icon/docs/_icon_fa_kit.md +7 -0
  38. data/app/pb_kits/playbook/pb_icon/docs/example.yml +2 -0
  39. data/app/pb_kits/playbook/pb_icon/docs/index.js +1 -0
  40. data/app/pb_kits/playbook/pb_icon/icon.rb +1 -1
  41. data/app/pb_kits/playbook/pb_icon_circle/_icon_circle.tsx +14 -4
  42. data/app/pb_kits/playbook/pb_icon_circle/icon_circle.rb +1 -1
  43. data/app/pb_kits/playbook/pb_icon_stat_value/_icon_stat_value.tsx +12 -1
  44. data/app/pb_kits/playbook/pb_icon_stat_value/docs/_icon_stat_value_color.html.erb +6 -0
  45. data/app/pb_kits/playbook/pb_icon_stat_value/docs/_icon_stat_value_color.jsx +9 -0
  46. data/app/pb_kits/playbook/pb_icon_stat_value/icon_stat_value.html.erb +16 -12
  47. data/app/pb_kits/playbook/pb_icon_stat_value/icon_stat_value.rb +2 -2
  48. data/app/pb_kits/playbook/pb_kit/dateTime.ts +139 -67
  49. data/app/pb_kits/playbook/pb_label_value/_label_value.tsx +52 -31
  50. data/app/pb_kits/playbook/pb_map/_map.scss +4 -0
  51. data/app/pb_kits/playbook/pb_message/_message.tsx +24 -24
  52. data/app/pb_kits/playbook/pb_time/_time.tsx +9 -11
  53. data/app/pb_kits/playbook/pb_time_range_inline/_time_range_inline.tsx +46 -49
  54. data/app/pb_kits/playbook/pb_time_stacked/_time_stacked.tsx +4 -6
  55. data/app/pb_kits/playbook/pb_timestamp/_timestamp.tsx +11 -11
  56. data/app/pb_kits/playbook/pb_weekday_stacked/_weekday_stacked.tsx +8 -11
  57. data/app/pb_kits/playbook/tokens/_colors.scss +4 -2
  58. data/app/pb_kits/playbook/utilities/_border_radius.scss +11 -1
  59. data/app/pb_kits/playbook/utilities/_line_height.scss +1 -2
  60. data/app/pb_kits/playbook/utilities/_shadow.scss +0 -1
  61. data/app/pb_kits/playbook/utilities/globalProps.ts +1 -1
  62. data/dist/playbook-rails.js +7 -7
  63. data/lib/playbook/version.rb +2 -2
  64. metadata +12 -8
  65. data/app/pb_kits/playbook/pb_logistic/_logistic.jsx +0 -120
@@ -7,351 +7,356 @@
7
7
  @import "../tokens/animation-curves";
8
8
  @import "../tokens/positioning";
9
9
 
10
-
11
-
12
- // Dialog Animations
13
- // Dialog Animations for fading in and out from the center
10
+ // Dialog animations
11
+ // Dialog animations for fading in and out from the center
14
12
  @keyframes modalFadeIn {
15
- from {
16
- transform: translate3d(0, -100%, 0);
17
- opacity: 0;
18
- }
19
- to {
20
- transform: translate3d(0, 0, 0);
21
- opacity: 1;
22
- }
13
+ from {
14
+ transform: translate3d(0, -100%, 0);
15
+ opacity: 0;
16
+ }
17
+ to {
18
+ transform: translate3d(0, 0, 0);
19
+ opacity: 1;
20
+ }
23
21
  }
24
22
 
25
23
  @keyframes modalFadeOut {
26
- from {
27
- transform: translate3d(0, 0, 0);
28
- opacity: 1;
29
- }
30
- to {
31
- transform: translate3d(0, -50%, 0);
32
- opacity: 0;
33
- }
24
+ from {
25
+ transform: translate3d(0, 0, 0);
26
+ opacity: 1;
27
+ }
28
+ to {
29
+ transform: translate3d(0, -50%, 0);
30
+ opacity: 0;
31
+ }
34
32
  }
35
33
 
36
- // Dialog Animations for fading in and out from the left side
34
+ // Dialog animations for fading in and out from the left side
37
35
  @keyframes modalFadeInLeft {
38
- from {
39
- transform: translate3d(-100%, 0, 0);
40
- opacity: 0;
41
- }
42
- to {
43
- transform: translate3d(0, 0, 0);
44
- opacity: 1;
45
- }
36
+ from {
37
+ transform: translate3d(-100%, 0, 0);
38
+ opacity: 0;
39
+ }
40
+ to {
41
+ transform: translate3d(0, 0, 0);
42
+ opacity: 1;
43
+ }
46
44
  }
47
45
 
48
46
  @keyframes modalFadeOutLeft {
49
- from {
50
- transform: translate3d(0, 0, 0);
51
- opacity: 1;
52
- }
53
- to {
54
- transform: translate3d(-50%, 0, 0);
55
- opacity: 0;
56
- }
47
+ from {
48
+ transform: translate3d(0, 0, 0);
49
+ opacity: 1;
50
+ }
51
+ to {
52
+ transform: translate3d(-50%, 0, 0);
53
+ opacity: 0;
54
+ }
57
55
  }
58
56
 
59
57
 
60
- // Dialog Animations for fading in and out from the right side
58
+ // Dialog animations for fading in and out from the right side
61
59
  @keyframes modalFadeInRight {
62
- from {
63
- transform: translate3d(100%, 0, 0);
64
- opacity: 0;
65
- }
66
- to {
67
- transform: translate3d(0, 0, 0);
68
- opacity: 1;
69
- }
60
+ from {
61
+ transform: translate3d(100%, 0, 0);
62
+ opacity: 0;
63
+ }
64
+ to {
65
+ transform: translate3d(0, 0, 0);
66
+ opacity: 1;
67
+ }
70
68
  }
71
69
 
72
70
  @keyframes modalFadeOutRight {
73
- from {
74
- transform: translate3d(0, 0, 0);
75
- opacity: 1;
76
- }
77
- to {
78
- transform: translate3d(50%, 0, 0);
79
- opacity: 0;
80
- }
71
+ from {
72
+ transform: translate3d(0, 0, 0);
73
+ opacity: 1;
74
+ }
75
+ to {
76
+ transform: translate3d(50%, 0, 0);
77
+ opacity: 0;
78
+ }
81
79
  }
82
80
 
83
81
  @keyframes overlayFade {
84
- from {
85
- opacity: 0;
86
- transform: translateY(0);
87
- }
88
- to {
89
- opacity: 1;
90
- transform: translateY(0);
91
- }
82
+ from {
83
+ opacity: 0;
84
+ transform: translateY(0);
85
+ }
86
+ to {
87
+ opacity: 1;
88
+ transform: translateY(0);
89
+ }
92
90
  }
93
91
 
94
92
  @keyframes overlayFadeOut {
95
- from {
96
- opacity: 1;
97
- }
98
- to {
99
- opacity: 0;
100
- }
93
+ from {
94
+ opacity: 1;
95
+ }
96
+ to {
97
+ opacity: 0;
98
+ }
101
99
  }
102
100
 
103
101
  // Dialog Styles
104
-
105
102
  .pb_dialog {
106
103
 
107
- // Local Variables
108
- $gutter: $space_lg;
109
- $small: 300px;
110
- $status_size: 375px;
111
- $medium: 500px;
112
- $large: 800px;
113
- $xlarge: 1150px;
114
- $animation-duration: .2s;
115
- $z-index: 100;
116
- $opacity_visible: 1;
117
- $opacity_hidden: 0;
118
-
119
- .dialog_sticky_header {
120
- position: sticky;
121
- top: 0;
122
- background-color: $white;
123
- z-index: $z_8;
124
- }
125
-
126
- // @include pb_card;
127
- background-color: $white;
128
- box-shadow: $shadow_deepest;
129
- border: 0;
130
- border-radius: $border_radius_md;
131
- max-height: calc(100vh - #{$gutter * 2});
132
- max-width: calc(100vw - #{$gutter * 2});
133
- overflow: auto;
134
- animation-name: modalFadeIn;
135
- animation-duration: $animation-duration;
136
- outline: none;
137
- animation-timing-function: $easeInOutQuint;
138
-
139
- &[class*="_left"] {
140
- animation-name: modalFadeInLeft;
141
- &[class*="_before_close"] {
142
- animation-name: modalFadeOutLeft;
143
- animation-duration: $animation-duration;
144
- opacity: $opacity_hidden;
145
- }
146
- }
147
-
148
- &[class*="_right"] {
149
- animation-name: modalFadeInRight;
150
- &[class*="_before_close"] {
151
- animation-name: modalFadeOutRight;
152
- animation-duration: $animation-duration;
153
- opacity: $opacity_hidden;
154
- }
155
- }
156
-
157
- &[class*="_status_size"] {
158
- width: $status_size;
159
- }
160
-
161
- &[class*="_sm"] {
162
- width: $small;
163
- }
164
-
165
- &[class*="_md"] {
166
- width: $medium;
167
- }
168
-
169
-
170
- &[class*="_lg"] {
171
- width: $large;
172
- }
173
-
174
- &_body_open {
175
- overflow: hidden;
176
- }
177
-
178
- &_after_open {
179
- opacity: $opacity_visible;
180
- }
181
-
182
- &[class*="_before_close"] {
183
- animation-name: modalFadeOut;
184
- animation-duration: $animation-duration;
185
- opacity: $opacity_hidden;
186
- }
187
-
188
- &_close_icon {
189
- cursor: pointer;
190
- }
191
-
192
- &_overlay {
193
- position: fixed;
194
- top: 0;
195
- left: 0;
196
- right: 0;
197
- bottom: 0;
198
- display: flex;
199
- align-items: center;
200
- justify-content: center;
201
- background-color: rgba($bg_dark, $opacity_4);
202
- z-index: $z-index;
203
- animation-name: overlayFade;
204
- animation-duration: $animation-duration;
205
-
206
- &_after_open {
207
- opacity: $opacity_visible;
208
- }
209
- &_before_close {
210
- animation-name: overlayFadeOut;
211
- animation-duration: $animation-duration;
212
- opacity: $opacity_hidden;
213
- }
214
- &[class*="full_height"] {
215
- &[class*="_left"]{
216
- justify-content: flex-start;
217
- }
218
-
219
- &[class*="_center"]{
220
- justify-content: center;
221
- }
222
-
223
- &[class*="_right"]{
224
- justify-content: flex-end;
225
- }
226
-
227
- .pb_dialog {
228
- border-radius: 0;
229
- height: 100%;
230
- max-height: 100%;
231
- max-width: none;
232
- //this empty div only has height when dialog is full height.
233
- //fix for dialog body content disappearing behind sticky footer
234
- .dialog-pseudo-footer {
235
- height: $space_xl * 2;
236
- }
237
- .dialog_footer {
238
- position:fixed;
239
- bottom: 0;
240
- background-color: $white;
241
- }
242
-
243
- &[class*="_sm"] {
244
- width: $medium;
245
- .dialog_footer {
246
- width: $medium;
247
- }
248
- }
249
- &[class*="_md"] {
250
- width: $large;
251
- .dialog_footer {
252
- width: $large;
253
- }
254
- }
255
- &[class*="_lg"] {
256
- width: $xlarge;
257
- .dialog_footer {
258
- width: $xlarge;
259
- }
260
- }
261
- }
262
- }
263
- }
104
+ // Local Variables
105
+ $gutter: $space_lg;
106
+ $small: 300px;
107
+ $status_size: 375px;
108
+ $medium: 500px;
109
+ $large: 800px;
110
+ $xlarge: 1150px;
111
+ $animation-duration: .2s;
112
+ $z-index: 100;
113
+ $opacity_visible: 1;
114
+ $opacity_hidden: 0;
115
+
116
+ .dialog_sticky_header {
117
+ position: sticky;
118
+ top: 0;
119
+ background-color: $white;
120
+ z-index: $z_8;
121
+ }
122
+
123
+ .dialog_status_text_align {
124
+ text-align: center;
125
+ }
126
+
127
+ // @include pb_card;
128
+ background-color: $white;
129
+ box-shadow: $shadow_deepest;
130
+ border: 0;
131
+ border-radius: $border_radius_md;
132
+ max-height: calc(100vh - #{$gutter * 2});
133
+ max-width: calc(100vw - #{$gutter * 2});
134
+ overflow: auto;
135
+ animation-name: modalFadeIn;
136
+ animation-duration: $animation-duration;
137
+ outline: none;
138
+ animation-timing-function: $easeInOutQuint;
139
+
140
+ &[class*="_left"] {
141
+ animation-name: modalFadeInLeft;
142
+ &[class*="_before_close"] {
143
+ animation-name: modalFadeOutLeft;
144
+ animation-duration: $animation-duration;
145
+ opacity: $opacity_hidden;
146
+ }
147
+ }
148
+
149
+ &[class*="_right"] {
150
+ animation-name: modalFadeInRight;
151
+ &[class*="_before_close"] {
152
+ animation-name: modalFadeOutRight;
153
+ animation-duration: $animation-duration;
154
+ opacity: $opacity_hidden;
155
+ }
156
+ }
157
+
158
+ &[class*="_status_size"] {
159
+ width: $status_size;
160
+ }
161
+
162
+ &[class*="_sm"] {
163
+ width: $small;
164
+ }
165
+
166
+ &[class*="_md"] {
167
+ width: $medium;
168
+ }
169
+
170
+ &[class*="_lg"] {
171
+ width: $large;
172
+ }
173
+
174
+ &_body_open {
175
+ overflow: hidden;
176
+ }
177
+
178
+ &_after_open {
179
+ opacity: $opacity_visible;
180
+ }
181
+
182
+ &[class*="_before_close"] {
183
+ animation-name: modalFadeOut;
184
+ animation-duration: $animation-duration;
185
+ opacity: $opacity_hidden;
186
+ }
187
+
188
+ &_close_icon {
189
+ cursor: pointer;
190
+ }
191
+
192
+ &_overlay {
193
+ position: fixed;
194
+ top: 0;
195
+ left: 0;
196
+ right: 0;
197
+ bottom: 0;
198
+ display: flex;
199
+ align-items: center;
200
+ justify-content: center;
201
+ background-color: rgba($bg_dark, $opacity_4);
202
+ z-index: $z-index;
203
+ animation-name: overlayFade;
204
+ animation-duration: $animation-duration;
205
+
206
+ &_after_open {
207
+ opacity: $opacity_visible;
208
+ }
209
+ &_before_close {
210
+ animation-name: overlayFadeOut;
211
+ animation-duration: $animation-duration;
212
+ opacity: $opacity_hidden;
213
+ }
214
+ &[class*="full_height"] {
215
+ &[class*="_left"]{
216
+ justify-content: flex-start;
217
+ }
218
+
219
+ &[class*="_center"]{
220
+ justify-content: center;
221
+ }
222
+
223
+ &[class*="_right"]{
224
+ justify-content: flex-end;
225
+ }
226
+
227
+ .pb_dialog {
228
+ border-radius: 0;
229
+ height: 100%;
230
+ max-height: 100%;
231
+ max-width: none;
232
+ // This empty div only has height when dialog is full height
233
+ // Fix for dialog body content disappearing behind sticky footer
234
+ .dialog-pseudo-footer {
235
+ height: $space_xl * 2;
236
+ }
237
+ .dialog_footer {
238
+ position:fixed;
239
+ bottom: 0;
240
+ background-color: $white;
241
+ }
242
+
243
+ &[class*="_sm"] {
244
+ width: $medium;
245
+ .dialog_footer {
246
+ width: $medium;
247
+ }
248
+ }
249
+ &[class*="_md"] {
250
+ width: $large;
251
+ .dialog_footer {
252
+ width: $large;
253
+ }
254
+ }
255
+ &[class*="_lg"] {
256
+ width: $xlarge;
257
+ .dialog_footer {
258
+ width: $xlarge;
259
+ }
260
+ }
261
+ }
262
+ }
263
+ }
264
264
  }
265
265
 
266
- //styles specific to rails version of kit
267
- // rails version has own wrapper because of the way the overlay functions for the HTML dialog used to create this
266
+ // Styles specific to Rails version of kit
267
+ // Rails version has own wrapper because of the way the overlay functions for the HTML dialog used to create this
268
268
  .pb_dialog_wrapper_rails {
269
- $medium: 500px;
270
- $large: 800px;
271
- $xlarge: 1150px;
272
-
273
- &[class*="full_height"] {
274
- &[class*="_left"]{
275
- .pb_dialog_rails {
276
- margin: unset !important;
277
- margin-right: auto !important;
278
- }
279
- }
280
-
281
- &[class*="_center"]{
282
- justify-content: center;
283
- }
284
-
285
- &[class*="_right"]{
286
- .pb_dialog_rails {
287
- margin: unset !important;
288
- margin-left: auto !important;
289
- }
290
- }
291
-
292
- .pb_dialog {
293
- border-radius: 0;
294
- height: 100% !important;
295
- max-height: 100% !important;
296
- max-width: 100%;
297
- //this empty div only has height when dialog is full height.
298
- //fix for dialog body content disappearing behind sticky footer
299
- .dialog-pseudo-footer {
300
- height: $space_xl * 2;
301
- }
302
- .dialog_footer {
303
- position:fixed;
304
- bottom: 0;
305
- background-color: $white;
306
- }
307
- &[class*="_sm"] {
308
- width: $medium;
309
- .dialog_footer {
310
- width: $medium;
311
- }
312
- }
313
- &[class*="_md"] {
314
- width: $large;
315
- .dialog_footer {
316
- width: $large;
317
- }
318
- }
319
- &[class*="_lg"] {
320
- width: $xlarge;
321
- .dialog_footer {
322
- width: $xlarge;
323
- }
324
- }
325
- }
326
- }
327
-
328
- // fixes for stylesheets in nitro that were conflicting with our kit. DO NOT REMOVE.
329
- //conflicts were only apparent in nitro, not in playbook local env
330
- .pb_dialog_rails {
331
- position: fixed !important;
332
- top: 0 !important;
333
- padding: unset !important;
334
- margin: auto;
335
-
336
- }
337
- //overlay for rails kit
338
- dialog::backdrop {
339
- position: fixed;
340
- top: 0;
341
- left: 0;
342
- right: 0;
343
- bottom: 0;
344
- display: flex;
345
- align-items: center;
346
- justify-content: center;
347
- background-color: rgba($bg_dark, $opacity_4);
348
- animation-name: overlayFade;
349
- animation-duration: 0.2s;
350
- }
351
-
352
- .dialog-button-class {
353
- background-color: unset;
354
- border: none;
355
- cursor: pointer;
356
- }
269
+ $medium: 500px;
270
+ $large: 800px;
271
+ $xlarge: 1150px;
272
+
273
+ .dialog_status_text_align {
274
+ text-align: center;
275
+ }
276
+
277
+ &[class*="full_height"] {
278
+ &[class*="_left"]{
279
+ .pb_dialog_rails {
280
+ margin: unset !important;
281
+ margin-right: auto !important;
282
+ }
283
+ }
284
+
285
+ &[class*="_center"]{
286
+ justify-content: center;
287
+ }
288
+
289
+ &[class*="_right"]{
290
+ .pb_dialog_rails {
291
+ margin: unset !important;
292
+ margin-left: auto !important;
293
+ }
294
+ }
295
+
296
+ .pb_dialog {
297
+ border-radius: 0;
298
+ height: 100% !important;
299
+ max-height: 100% !important;
300
+ max-width: 100%;
301
+ // This empty div only has height when dialog is full height.
302
+ // Fix for dialog body content disappearing behind sticky footer
303
+ .dialog-pseudo-footer {
304
+ height: $space_xl * 2;
305
+ }
306
+ .dialog_footer {
307
+ position:fixed;
308
+ bottom: 0;
309
+ background-color: $white;
310
+ }
311
+ &[class*="_sm"] {
312
+ width: $medium;
313
+ .dialog_footer {
314
+ width: $medium;
315
+ }
316
+ }
317
+ &[class*="_md"] {
318
+ width: $large;
319
+ .dialog_footer {
320
+ width: $large;
321
+ }
322
+ }
323
+ &[class*="_lg"] {
324
+ width: $xlarge;
325
+ .dialog_footer {
326
+ width: $xlarge;
327
+ }
328
+ }
329
+ }
330
+ }
331
+
332
+ // Fixes for stylesheets in nitro that were conflicting with our kit. DO NOT REMOVE.
333
+ // Conflicts were only apparent in nitro, not in playbook local env
334
+ .pb_dialog_rails {
335
+ position: fixed !important;
336
+ top: 0 !important;
337
+ padding: unset !important;
338
+ margin: auto;
339
+
340
+ }
341
+
342
+ // Overlay for rails kit
343
+ dialog::backdrop {
344
+ position: fixed;
345
+ top: 0;
346
+ left: 0;
347
+ right: 0;
348
+ bottom: 0;
349
+ display: flex;
350
+ align-items: center;
351
+ justify-content: center;
352
+ background-color: rgba($bg_dark, $opacity_4);
353
+ animation-name: overlayFade;
354
+ animation-duration: 0.2s;
355
+ }
356
+
357
+ .dialog-button-class {
358
+ background-color: unset;
359
+ border: none;
360
+ cursor: pointer;
361
+ }
357
362
  }