playbook_ui 13.19.0.pre.alpha.play1174fixconfimationtoastmobilebug2305 → 13.19.0.pre.alpha.play1186collapsiblenaviconcolorbug2321
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_fixed_confirmation_toast/_fixed_confirmation_toast.scss +0 -8
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_multi_line.html.erb +1 -32
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_multi_line.jsx +4 -38
- data/app/pb_kits/playbook/pb_nav/_subtle_mixin.scss +4 -0
- data/lib/playbook/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d4a0c9535e1e8a18819885ccf9f8a0cb1f99d043dfe98b8139e1c5eb25538a07
|
4
|
+
data.tar.gz: 8d1b59b1dba9d078a97621ad906f6e73ec52e18104b6b1b286188cd4041f64fd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7e8d6d9fbf50224808ef954c507edddd5a6960ae123af18130915008ab45bd8992c1443259ab04cb70f5f48930c889de87dfacbbf7b2296c4a84545240762a18
|
7
|
+
data.tar.gz: 2d1d0a1c3dcef04a3fb90b667aa6bbbf3410a36c5b8a2ce12dc08d24c340608656573bf3f5188569ac44658affc245f81afb6cb3440a4f1f4f4f5d9400b4a7bb
|
@@ -56,14 +56,6 @@ $confirmation_toast_colors: (
|
|
56
56
|
transform: translateX(-50%);
|
57
57
|
}
|
58
58
|
|
59
|
-
@media only screen and (max-width: 600px) {
|
60
|
-
&.center {
|
61
|
-
left: 5%;
|
62
|
-
right: 5%;
|
63
|
-
transform: translateX(-0%);
|
64
|
-
}
|
65
|
-
}
|
66
|
-
|
67
59
|
&.right {
|
68
60
|
left: auto;
|
69
61
|
right: $space_md;
|
@@ -1,36 +1,5 @@
|
|
1
|
-
<%= pb_rails("button", props: { text: "Multiline Example", variant: "primary", data: { toast: "#toast-top-center-multi" } }) %>
|
2
|
-
|
3
1
|
<%= pb_rails("fixed_confirmation_toast", props: {
|
4
|
-
classname: "toast-to-hide",
|
5
|
-
closeable: true,
|
6
|
-
id: "toast-top-center-multi",
|
7
2
|
multi_line: true,
|
8
|
-
text: "
|
3
|
+
text: "Scan to Assign Selected Items. Click here to generate report",
|
9
4
|
status: "tip",
|
10
|
-
vertical: "top",
|
11
|
-
horizontal: "center"
|
12
5
|
}) %>
|
13
|
-
|
14
|
-
<script type="text/javascript">
|
15
|
-
const alltoasts = document.queryselectorall(".toast-to-hide")
|
16
|
-
const allbuttons = document.queryselectorall("button[data-toast]")
|
17
|
-
|
18
|
-
const hidealltoasts = () => {
|
19
|
-
alltoasts.foreach((toast) => {
|
20
|
-
toast.style.display = "none"
|
21
|
-
})
|
22
|
-
}
|
23
|
-
|
24
|
-
hidealltoasts()
|
25
|
-
|
26
|
-
allbuttons.foreach((button) => {
|
27
|
-
button.onclick = () => {
|
28
|
-
hidealltoasts()
|
29
|
-
let toast = document.queryselector(button.getattribute("data-toast"))
|
30
|
-
|
31
|
-
if (toast) {
|
32
|
-
toast.style.display = "flex"
|
33
|
-
}
|
34
|
-
}
|
35
|
-
})
|
36
|
-
</script>
|
data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_fixed_confirmation_toast_multi_line.jsx
CHANGED
@@ -1,52 +1,18 @@
|
|
1
|
+
import React from 'react'
|
1
2
|
|
2
|
-
import React, { useState } from 'react'
|
3
|
-
|
4
|
-
import Button from '../../pb_button/_button'
|
5
3
|
import FixedConfirmationToast from '../_fixed_confirmation_toast'
|
6
4
|
|
7
|
-
const
|
8
|
-
const [state, setState] = useState({
|
9
|
-
open: false,
|
10
|
-
vertical: 'top',
|
11
|
-
horizontal: 'center',
|
12
|
-
})
|
13
|
-
|
14
|
-
const { vertical, horizontal, open } = state
|
15
|
-
|
16
|
-
const handleClick = (newState) => () => {
|
17
|
-
setState({ open: true, ...newState })
|
18
|
-
}
|
19
|
-
|
20
|
-
const handleClose = () => {
|
21
|
-
setState({ ...state, open: false })
|
22
|
-
}
|
23
|
-
|
5
|
+
const FixedConfirmationToastMultiLine = (props) => {
|
24
6
|
return (
|
25
7
|
<div>
|
26
|
-
<Button
|
27
|
-
onClick={handleClick({
|
28
|
-
horizontal: 'center',
|
29
|
-
open: true,
|
30
|
-
vertical: 'top',
|
31
|
-
})}
|
32
|
-
text="Multiline Example"
|
33
|
-
variant="primary"
|
34
|
-
{...props}
|
35
|
-
/>
|
36
|
-
{' '}
|
37
8
|
<FixedConfirmationToast
|
38
|
-
closeable
|
39
|
-
horizontal={horizontal}
|
40
9
|
multiLine
|
41
|
-
onClose={handleClose}
|
42
|
-
open={open}
|
43
10
|
status="tip"
|
44
|
-
text=
|
45
|
-
vertical={vertical}
|
11
|
+
text="Scan to Assign Selected Items. Click here to generate report"
|
46
12
|
{...props}
|
47
13
|
/>
|
48
14
|
</div>
|
49
15
|
)
|
50
16
|
}
|
51
17
|
|
52
|
-
export default
|
18
|
+
export default FixedConfirmationToastMultiLine
|
data/lib/playbook/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: playbook_ui
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 13.19.0.pre.alpha.
|
4
|
+
version: 13.19.0.pre.alpha.play1186collapsiblenaviconcolorbug2321
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Power UX
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2024-03-
|
12
|
+
date: 2024-03-07 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: actionpack
|