playbook_ui 14.11.1.pre.alpha.PLAY1751pbcontenttagpt25529 → 14.11.1.pre.alpha.PLAY17445539
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.
- checksums.yaml +4 -4
- data/app/pb_kits/playbook/pb_drawer/_drawer.scss +154 -177
- data/app/pb_kits/playbook/pb_drawer/_drawer.tsx +162 -264
- data/app/pb_kits/playbook/pb_drawer/context.ts +11 -0
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_behavior.jsx +38 -0
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_borders.jsx +3 -45
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_breakpoints.jsx +0 -1
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_default.jsx +9 -16
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_menu.jsx +44 -19
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_menu.md +21 -3
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_overlay.jsx +16 -21
- data/app/pb_kits/playbook/pb_drawer/docs/_drawer_sizes.jsx +2 -19
- data/app/pb_kits/playbook/pb_drawer/docs/example.yml +2 -1
- data/app/pb_kits/playbook/pb_drawer/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_drawer/drawer.test.jsx +5 -5
- data/app/pb_kits/playbook/pb_drawer/hooks/useBreakpoint.tsx +73 -0
- data/app/pb_kits/playbook/pb_drawer/hooks/useDrawerAnimation.tsx +21 -0
- data/app/pb_kits/playbook/pb_file_upload/file_upload.html.erb +6 -1
- data/app/pb_kits/playbook/pb_filter/filter.html.erb +5 -1
- data/app/pb_kits/playbook/pb_form_group/form_group.html.erb +6 -1
- data/app/pb_kits/playbook/pb_form_pill/form_pill.html.erb +1 -1
- data/dist/chunks/{_typeahead-TN5aDUj9.js → _typeahead-vFuUQM5F.js} +1 -1
- data/dist/chunks/_weekday_stacked-DG3A22sS.js +45 -0
- data/dist/chunks/vendor.js +1 -1
- data/dist/playbook-doc.js +1 -1
- data/dist/playbook-rails-react-bindings.js +1 -1
- data/dist/playbook-rails.js +1 -1
- data/dist/playbook.css +1 -1
- data/lib/playbook/version.rb +1 -1
- metadata +7 -3
- data/dist/chunks/_weekday_stacked-BcnpLG66.js +0 -45
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fc87bec1a3c8f7ff6d6e2ba75803628c9e58603b3cdeb99e594fbe848eef5744
|
4
|
+
data.tar.gz: 6ff0f99215db0507635fde51c622a3b958b5c7b838b7bc3ddc33dc274956263a
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 166e0a325c792b7ca130740893dbb9e77af28360afb2371b88a240b3692fcff92f6a1499fff7c943b900c00a788e1db1605c94401b55377ace1ffd0e7d742af9
|
7
|
+
data.tar.gz: ac0c4fb79a12b76a1915ae45a5d3a6936003c5b40127fe1cc34f51b4f03e2831588f9baa3f3caaeaa7a09dd29ce85fde825e4ed3ae6002656c0431f88e14154b
|
@@ -13,10 +13,9 @@ $small: 200px;
|
|
13
13
|
$medium: 250px;
|
14
14
|
$large: 300px;
|
15
15
|
$xlarge: 365px;
|
16
|
-
$animation-duration:
|
16
|
+
$animation-duration: .25s;
|
17
17
|
$z-index: $z_7;
|
18
18
|
|
19
|
-
// Drawer animations
|
20
19
|
@keyframes modalFadeInLeft {
|
21
20
|
from {
|
22
21
|
transform: translateX(-100%);
|
@@ -71,6 +70,62 @@ $z-index: $z_7;
|
|
71
70
|
}
|
72
71
|
}
|
73
72
|
|
73
|
+
@keyframes overlayFade {
|
74
|
+
from {
|
75
|
+
opacity: 0;
|
76
|
+
transform: translateY(0);
|
77
|
+
}
|
78
|
+
to {
|
79
|
+
opacity: 1;
|
80
|
+
transform: translateY(0);
|
81
|
+
}
|
82
|
+
}
|
83
|
+
|
84
|
+
@keyframes overlayFadeOut {
|
85
|
+
from {
|
86
|
+
opacity: 1;
|
87
|
+
}
|
88
|
+
to {
|
89
|
+
opacity: 0;
|
90
|
+
}
|
91
|
+
}
|
92
|
+
|
93
|
+
@keyframes modalFadeDownIn {
|
94
|
+
from {
|
95
|
+
transform: translateY(-100%);
|
96
|
+
}
|
97
|
+
to {
|
98
|
+
transform: translateY(0);
|
99
|
+
}
|
100
|
+
}
|
101
|
+
|
102
|
+
@keyframes modalFadeDownOut {
|
103
|
+
from {
|
104
|
+
transform: translateY(0);
|
105
|
+
}
|
106
|
+
to {
|
107
|
+
transform: translateY(-100%);
|
108
|
+
}
|
109
|
+
}
|
110
|
+
|
111
|
+
@keyframes modalFadeUpIn {
|
112
|
+
from {
|
113
|
+
transform: translateY(100%);
|
114
|
+
}
|
115
|
+
to {
|
116
|
+
transform: translateY(0);
|
117
|
+
}
|
118
|
+
}
|
119
|
+
|
120
|
+
@keyframes modalFadeUpOut {
|
121
|
+
from {
|
122
|
+
transform: translateY(0);
|
123
|
+
}
|
124
|
+
to {
|
125
|
+
transform: translateY(100%);
|
126
|
+
}
|
127
|
+
}
|
128
|
+
|
74
129
|
body.PBDrawer__Body--open {
|
75
130
|
transition: margin-left $animation-duration ease-in, margin-right $animation-duration ease-in;
|
76
131
|
}
|
@@ -94,34 +149,53 @@ body.PBDrawer__Body--close {
|
|
94
149
|
|
95
150
|
// Drawer Styles
|
96
151
|
.pb_drawer {
|
97
|
-
|
98
|
-
|
152
|
+
background-color: $white;
|
153
|
+
z-index: $z-index;
|
154
|
+
border: 0;
|
155
|
+
height: 100%;
|
156
|
+
overflow: auto;
|
157
|
+
animation-duration: $animation-duration;
|
158
|
+
outline: none;
|
159
|
+
|
160
|
+
&.pb_drawer_within_element {
|
161
|
+
position: relative;
|
162
|
+
width: 100%;
|
163
|
+
display: block;
|
164
|
+
background-color: $white;
|
165
|
+
overflow: hidden;
|
166
|
+
transition: height $animation-duration ease-in-out;
|
167
|
+
height: var(--drawer-height);
|
168
|
+
z-index: 1;
|
169
|
+
|
170
|
+
&.pb_drawer_collapsing {
|
171
|
+
height: 0;
|
172
|
+
}
|
173
|
+
|
174
|
+
&::before {
|
175
|
+
content: '';
|
176
|
+
position: absolute;
|
177
|
+
top: 0;
|
178
|
+
left: 0;
|
179
|
+
right: 0;
|
180
|
+
bottom: 0;
|
181
|
+
background-color: inherit;
|
182
|
+
z-index: -1;
|
183
|
+
}
|
184
|
+
}
|
185
|
+
|
186
|
+
.toggle-content.is-visible {
|
187
|
+
display: block;
|
188
|
+
height: auto;
|
189
|
+
}
|
99
190
|
|
100
191
|
.drawer {
|
101
192
|
position: sticky;
|
102
193
|
will-change: transform;
|
103
|
-
backface-visibility: hidden;
|
104
194
|
top: 0;
|
105
195
|
background-color: $white;
|
106
196
|
z-index: $z_9;
|
107
197
|
}
|
108
198
|
|
109
|
-
// @include pb_card;
|
110
|
-
background-color: $white;
|
111
|
-
border: 0;
|
112
|
-
box-shadow: $shadow_deepest; // border class here
|
113
|
-
max-height: calc(100vh - #{$gutter * 2});
|
114
|
-
max-width: calc(100vw - #{$gutter * 2});
|
115
|
-
overflow: auto;
|
116
|
-
animation-duration: $animation-duration;
|
117
|
-
outline: none;
|
118
|
-
|
119
|
-
// General _before_close styles
|
120
|
-
&[class*="_before_close"] {
|
121
|
-
animation-name: modalFadeOut;
|
122
|
-
animation-duration: $animation-duration;
|
123
|
-
}
|
124
|
-
|
125
199
|
&[class*="_left"] {
|
126
200
|
animation-name: modalFadeInLeft;
|
127
201
|
}
|
@@ -129,17 +203,40 @@ body.PBDrawer__Body--close {
|
|
129
203
|
&[class*="_left"][class*="_before_close"] {
|
130
204
|
animation-name: modalFadeOutLeft;
|
131
205
|
animation-duration: $animation-duration;
|
206
|
+
transform: translateX(-100%);
|
132
207
|
}
|
133
208
|
|
134
209
|
&[class*="_right"] {
|
135
210
|
animation-name: modalFadeInRight;
|
211
|
+
justify-content: flex-end;
|
136
212
|
}
|
137
213
|
|
138
214
|
&[class*="_right"][class*="_before_close"] {
|
139
215
|
animation-name: modalFadeOutRight;
|
140
216
|
animation-duration: $animation-duration;
|
217
|
+
transform: translateX(100%);
|
218
|
+
}
|
219
|
+
|
220
|
+
&[class*="_bottom"] {
|
221
|
+
animation: none;
|
222
|
+
transform: none;
|
223
|
+
}
|
224
|
+
|
225
|
+
&[class*="_bottom"][class*="_before_close"] {
|
226
|
+
animation: none;
|
227
|
+
transform: none;
|
228
|
+
}
|
229
|
+
|
230
|
+
&[class*="_top"] {
|
231
|
+
animation-name: modalFadeUpIn;
|
141
232
|
}
|
142
233
|
|
234
|
+
&[class*="_top"][class*="_before_close"] {
|
235
|
+
animation-name: modalFadeUpOut;
|
236
|
+
animation-duration: $animation-duration;
|
237
|
+
}
|
238
|
+
|
239
|
+
|
143
240
|
&[class*="_xs_"] {
|
144
241
|
width: $xsmall;
|
145
242
|
max-width: $xsmall;
|
@@ -165,23 +262,25 @@ body.PBDrawer__Body--close {
|
|
165
262
|
max-width: $xlarge;
|
166
263
|
}
|
167
264
|
|
168
|
-
&
|
169
|
-
|
265
|
+
&[class*="_full_"] {
|
266
|
+
width: 100%;
|
267
|
+
max-width: 100%;
|
170
268
|
}
|
171
269
|
|
172
|
-
&
|
270
|
+
&_body_open {
|
271
|
+
overflow: hidden;
|
173
272
|
}
|
174
273
|
|
175
|
-
&.
|
274
|
+
&.drawer_border-full {
|
176
275
|
box-shadow: none;
|
177
276
|
border: 2px solid #f3f7fb;
|
178
277
|
}
|
179
278
|
|
180
|
-
&.
|
279
|
+
&.drawer_border-right {
|
181
280
|
border-right: 2px solid #f3f7fb;
|
182
281
|
}
|
183
282
|
|
184
|
-
&.
|
283
|
+
&.drawer_border-left {
|
185
284
|
border-left: 2px solid #f3f7fb;
|
186
285
|
}
|
187
286
|
|
@@ -200,78 +299,30 @@ body.PBDrawer__Body--close {
|
|
200
299
|
right: 0;
|
201
300
|
bottom: 0;
|
202
301
|
display: flex;
|
203
|
-
align-items: center;
|
204
|
-
justify-content: center;
|
205
302
|
background-color: rgba($bg_dark, $opacity_4);
|
206
303
|
z-index: $z-index;
|
207
|
-
|
208
|
-
animation
|
304
|
+
opacity: 0;
|
305
|
+
animation: overlayFade $animation-duration ease-in-out forwards;
|
306
|
+
|
307
|
+
&[class*="_left"]{
|
308
|
+
justify-content: flex-start;
|
309
|
+
}
|
310
|
+
|
311
|
+
&[class*="_center"]{
|
312
|
+
justify-content: center;
|
313
|
+
}
|
314
|
+
|
315
|
+
&[class*="_right"]{
|
316
|
+
justify-content: flex-end;
|
317
|
+
}
|
209
318
|
|
210
319
|
&_after_open {
|
320
|
+
opacity: 1;
|
211
321
|
}
|
322
|
+
|
212
323
|
&_before_close {
|
213
|
-
animation
|
214
|
-
|
215
|
-
}
|
216
|
-
&[class*="full_height"] {
|
217
|
-
&[class*="_left"]{
|
218
|
-
justify-content: flex-start;
|
219
|
-
}
|
220
|
-
|
221
|
-
&[class*="_center"]{
|
222
|
-
justify-content: center;
|
223
|
-
}
|
224
|
-
|
225
|
-
&[class*="_right"]{
|
226
|
-
justify-content: flex-end;
|
227
|
-
}
|
228
|
-
|
229
|
-
.pb_drawer {
|
230
|
-
height: 100%;
|
231
|
-
max-height: 100%;
|
232
|
-
max-width: none;
|
233
|
-
// This empty div only has height when drawer is full height
|
234
|
-
// Fix for drawer body content disappearing behind sticky footer
|
235
|
-
.drawer-pseudo-footer {
|
236
|
-
height: $space_xl * 2;
|
237
|
-
}
|
238
|
-
.drawer_footer {
|
239
|
-
position: fixed;
|
240
|
-
bottom: 0;
|
241
|
-
background-color: $white;
|
242
|
-
max-width: 100%;
|
243
|
-
}
|
244
|
-
&[class*="_xs_"] {
|
245
|
-
width: $xsmall;
|
246
|
-
.dialog_footer {
|
247
|
-
width: $xsmall;
|
248
|
-
}
|
249
|
-
}
|
250
|
-
&[class*="_sm_"] {
|
251
|
-
width: $small;
|
252
|
-
.dialog_footer {
|
253
|
-
width: $small;
|
254
|
-
}
|
255
|
-
}
|
256
|
-
&[class*="_md_"] {
|
257
|
-
width: $medium;
|
258
|
-
.dialog_footer {
|
259
|
-
width: $medium;
|
260
|
-
}
|
261
|
-
}
|
262
|
-
&[class*="_lg_"] {
|
263
|
-
width: $large;
|
264
|
-
.dialog_footer {
|
265
|
-
width: $large;
|
266
|
-
}
|
267
|
-
}
|
268
|
-
&[class*="_xl_"] {
|
269
|
-
width: $xlarge;
|
270
|
-
.dialog_footer {
|
271
|
-
width: $xlarge;
|
272
|
-
}
|
273
|
-
}
|
274
|
-
}
|
324
|
+
animation: overlayFadeOut $animation-duration ease-in-out forwards;
|
325
|
+
opacity: 0;
|
275
326
|
}
|
276
327
|
}
|
277
328
|
|
@@ -281,99 +332,25 @@ body.PBDrawer__Body--close {
|
|
281
332
|
left: 0;
|
282
333
|
right: 0;
|
283
334
|
bottom: 0;
|
284
|
-
display: flex;
|
285
|
-
align-items: center;
|
286
|
-
justify-content: center;
|
287
335
|
z-index: $z-index;
|
288
|
-
|
289
|
-
animation
|
290
|
-
|
291
|
-
pointer-events: none; /* Allow interaction inside the drawer itself */
|
292
|
-
|
293
|
-
body.PBDrawer--open {
|
294
|
-
overflow: none; /* Ensure body remains scrollable */
|
295
|
-
pointer-events: none; /* Allow interaction inside the drawer itself */
|
296
|
-
}
|
336
|
+
opacity: 1;
|
337
|
+
animation: overlayFade $animation-duration ease-in-out forwards;
|
338
|
+
pointer-events: none;
|
297
339
|
|
298
340
|
&_after_open {
|
299
|
-
|
300
|
-
pointer-events: none; /* Allow interaction inside the drawer itself */
|
341
|
+
opacity: 1;
|
301
342
|
}
|
343
|
+
|
302
344
|
&_before_close {
|
303
|
-
animation
|
304
|
-
animation-duration: $animation-duration;
|
305
|
-
}
|
306
|
-
&[class*="full_height"] {
|
307
|
-
&[class*="_left"]{
|
308
|
-
justify-content: flex-start;
|
309
|
-
}
|
310
|
-
|
311
|
-
&[class*="_center"]{
|
312
|
-
justify-content: center;
|
313
|
-
}
|
314
|
-
|
315
|
-
&[class*="_right"]{
|
316
|
-
justify-content: flex-end;
|
317
|
-
}
|
318
|
-
|
319
|
-
.pb_drawer {
|
320
|
-
height: 100%;
|
321
|
-
max-height: 100%;
|
322
|
-
max-width: none;
|
323
|
-
// This empty div only has height when drawer is full height
|
324
|
-
// Fix for drawer body content disappearing behind sticky footer
|
325
|
-
.drawer-pseudo-footer {
|
326
|
-
height: $space_xl * 2;
|
327
|
-
}
|
328
|
-
.drawer_footer {
|
329
|
-
position: fixed;
|
330
|
-
bottom: 0;
|
331
|
-
background-color: $white;
|
332
|
-
max-width: 100%;
|
333
|
-
}
|
334
|
-
&[class*="_xs_"] {
|
335
|
-
width: $xsmall;
|
336
|
-
.dialog_footer {
|
337
|
-
width: $xsmall;
|
338
|
-
}
|
339
|
-
}
|
340
|
-
&[class*="_sm_"] {
|
341
|
-
width: $small;
|
342
|
-
.dialog_footer {
|
343
|
-
width: $small;
|
344
|
-
}
|
345
|
-
}
|
346
|
-
&[class*="_md_"] {
|
347
|
-
width: $medium;
|
348
|
-
.dialog_footer {
|
349
|
-
width: $medium;
|
350
|
-
}
|
351
|
-
}
|
352
|
-
&[class*="_lg_"] {
|
353
|
-
width: $large;
|
354
|
-
.dialog_footer {
|
355
|
-
width: $large;
|
356
|
-
}
|
357
|
-
}
|
358
|
-
&[class*="_xl_"] {
|
359
|
-
width: $xlarge;
|
360
|
-
.dialog_footer {
|
361
|
-
width: $xlarge;
|
362
|
-
}
|
363
|
-
}
|
364
|
-
}
|
345
|
+
animation: overlayFadeOut $animation-duration ease-in-out forwards;
|
365
346
|
}
|
366
347
|
}
|
367
348
|
|
368
|
-
|
369
|
-
|
370
|
-
}
|
371
|
-
|
372
|
-
[class*="drawer_header"] {
|
373
|
-
padding: $space_sm;
|
349
|
+
&.pb_drawer_after_open {
|
350
|
+
transform: translateX(0);
|
374
351
|
}
|
375
352
|
|
376
|
-
|
377
|
-
|
353
|
+
&.pb_drawer_before_close {
|
354
|
+
transform: translateX(-100%);
|
378
355
|
}
|
379
356
|
}
|