playbook_ui_docs 14.17.0.pre.alpha.PLAY20267223 → 14.17.0.pre.alpha.alphaforaudiences7167

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 (28) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +0 -1
  3. data/app/pb_kits/playbook/pb_advanced_table/docs/index.js +1 -2
  4. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones.jsx +105 -102
  5. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones.md +3 -3
  6. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors.jsx +48 -50
  7. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors.md +1 -1
  8. data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_table.jsx → _draggable_with_table_react.jsx} +1 -1
  9. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table_react.md +1 -3
  10. data/app/pb_kits/playbook/pb_draggable/docs/example.yml +6 -9
  11. data/app/pb_kits/playbook/pb_draggable/docs/index.js +1 -4
  12. data/dist/playbook-doc.js +1 -1
  13. metadata +14 -18
  14. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_sticky_columns.jsx +0 -58
  15. data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_sticky_columns.md +0 -6
  16. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_line.jsx +0 -110
  17. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_line.md +0 -5
  18. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_default_react.md → _draggable_default.md} +0 -0
  19. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_default.html.erb → _draggable_default_rails.html.erb} +0 -0
  20. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_multiple_containers_react.md → _draggable_multiple_containers.md} +0 -0
  21. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_multiple_containers.html.erb → _draggable_multiple_containers_rails.html.erb} +0 -0
  22. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_cards_react.md → _draggable_with_cards.md} +0 -0
  23. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_cards.html.erb → _draggable_with_cards_rails.html.erb} +0 -0
  24. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_list_react.md → _draggable_with_list.md} +0 -0
  25. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_list.html.erb → _draggable_with_list_rails.html.erb} +0 -0
  26. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_selectable_list_react.md → _draggable_with_selectable_list.md} +0 -0
  27. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_selectable_list.html.erb → _draggable_with_selectable_list_rails.html.erb} +0 -0
  28. /data/app/pb_kits/playbook/pb_draggable/docs/{_draggable_with_table_rails.md → _draggable_with_table.md} +0 -0
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: playbook_ui_docs
3
3
  version: !ruby/object:Gem::Version
4
- version: 14.17.0.pre.alpha.PLAY20267223
4
+ version: 14.17.0.pre.alpha.alphaforaudiences7167
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: 2025-04-15 00:00:00.000000000 Z
12
+ date: 2025-04-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: playbook_ui
@@ -93,8 +93,6 @@ files:
93
93
  - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_sort.md
94
94
  - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_sort_control.jsx
95
95
  - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_sort_control.md
96
- - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_sticky_columns.jsx
97
- - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_sticky_columns.md
98
96
  - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_subrow_headers.jsx
99
97
  - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_subrow_headers.md
100
98
  - app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_table_options.jsx
@@ -708,35 +706,33 @@ files:
708
706
  - app/pb_kits/playbook/pb_distribution_bar/docs/_distribution_bar_default.jsx
709
707
  - app/pb_kits/playbook/pb_distribution_bar/docs/example.yml
710
708
  - app/pb_kits/playbook/pb_distribution_bar/docs/index.js
711
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_default.html.erb
712
709
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_default.jsx
710
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_default.md
711
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_default_rails.html.erb
713
712
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_default_rails.md
714
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_default_react.md
715
713
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones.jsx
716
714
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones.md
717
715
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors.jsx
718
716
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_colors.md
719
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_line.jsx
720
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_drop_zones_line.md
721
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers.html.erb
722
717
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers.jsx
718
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers.md
719
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers_rails.html.erb
723
720
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers_rails.md
724
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers_react.md
725
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards.html.erb
726
721
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards.jsx
722
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards.md
723
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards_rails.html.erb
727
724
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards_rails.md
728
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards_react.md
729
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list.html.erb
730
725
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list.jsx
726
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list.md
727
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list_rails.html.erb
731
728
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list_rails.md
732
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list_react.md
733
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list.html.erb
734
729
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list.jsx
730
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list.md
731
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list_rails.html.erb
735
732
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list_rails.md
736
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list_react.md
737
733
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table.html.erb
738
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table.jsx
739
- - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table_rails.md
734
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table.md
735
+ - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table_react.jsx
740
736
  - app/pb_kits/playbook/pb_draggable/docs/_draggable_with_table_react.md
741
737
  - app/pb_kits/playbook/pb_draggable/docs/example.yml
742
738
  - app/pb_kits/playbook/pb_draggable/docs/index.js
@@ -1,58 +0,0 @@
1
- import React from "react"
2
- import AdvancedTable from '../../pb_advanced_table/_advanced_table'
3
- import MOCK_DATA from "./advanced_table_mock_data.json"
4
-
5
- const AdvancedTableStickyColumns = (props) => {
6
- const columnDefinitions = [
7
- {
8
- accessor: "year",
9
- label: "Year",
10
- id: "year",
11
- cellAccessors: ["quarter", "month", "day"],
12
- },
13
- {
14
- accessor: "newEnrollments",
15
- label: "New Enrollments",
16
- id: "newEnrollments",
17
- },
18
- {
19
- accessor: "scheduledMeetings",
20
- label: "Scheduled Meetings",
21
- id: "scheduledMeetings",
22
- },
23
- {
24
- accessor: "attendanceRate",
25
- label: "Attendance Rate",
26
- id: "attendanceRate",
27
- },
28
- {
29
- accessor: "completedClasses",
30
- label: "Completed Classes",
31
- id: "completedClasses",
32
- },
33
- {
34
- accessor: "classCompletionRate",
35
- label: "Class Completion Rate",
36
- id: "classCompletionRate",
37
- },
38
- {
39
- accessor: "graduatedStudents",
40
- label: "Graduated Students",
41
- id: "graduatedStudents",
42
- },
43
- ]
44
-
45
- return (
46
- <div>
47
- <AdvancedTable
48
- columnDefinitions={columnDefinitions}
49
- responsive="none"
50
- stickyLeftColumn={["year", "newEnrollments"]}
51
- tableData={MOCK_DATA}
52
- {...props}
53
- />
54
- </div>
55
- )
56
- }
57
-
58
- export default AdvancedTableStickyColumns
@@ -1,6 +0,0 @@
1
- To render sticky columns for the Advanced Table, you can use the `stickyLeftColumn` prop. This prop expects an array of the column ids you want to be sticky.
2
-
3
- To achieve this:
4
- - Make sure to provide an id for each column via columnDefinitions as shown below. Id can be any string.
5
- - One or multiple columns can be made sticky, it is recommended to set the ids within `stickyLeftColumn` in the order in which the columns are rendered.
6
- - It is recommended to set `responsive` to none when using `stickyLeftColumn` since responsive just makes the first column sticky and the slightly different styling for `responsive` and `stickyLeftColumn` may override each other in unexpected ways.
@@ -1,110 +0,0 @@
1
- import React, { useState } from "react";
2
- import Flex from '../../pb_flex/_flex'
3
- import Caption from '../../pb_caption/_caption'
4
- import Draggable from '../_draggable'
5
- import { DraggableProvider } from '../context'
6
- import Image from '../../pb_image/_image'
7
-
8
-
9
-
10
- const dataLineVertical = [
11
- {
12
- id: "211",
13
- url: "https://unsplash.it/500/400/?image=633",
14
- },
15
- {
16
- id: "212",
17
- url: "https://unsplash.it/500/400/?image=634",
18
- },
19
- {
20
- id: "213",
21
- url: "https://unsplash.it/500/400/?image=637",
22
- },
23
- ];
24
-
25
- const dataLineHorizontal = [
26
- {
27
- id: "2111",
28
- url: "https://unsplash.it/500/400/?image=633",
29
- },
30
- {
31
- id: "2122",
32
- url: "https://unsplash.it/500/400/?image=634",
33
- },
34
- {
35
- id: "2133",
36
- url: "https://unsplash.it/500/400/?image=637",
37
- },
38
- ];
39
-
40
- const DraggableDropZones = (props) => {
41
- const [initialLineVerticalState, setInitialLineVerticalState] = useState(dataLineVertical);
42
- const [initialLineHorizontalState, setInitialLineHorizontalState] = useState(dataLineHorizontal);
43
-
44
- return (
45
- <>
46
- <Caption marginBottom="xs"
47
- marginTop="xl"
48
- text="Vertical"
49
- />
50
- <DraggableProvider
51
- dropZone={{ type: "line", color: "purple" }}
52
- initialItems={dataLineVertical}
53
- onReorder={(items) => setInitialLineVerticalState(items)}
54
- >
55
- <Draggable.Container {...props}>
56
- <Flex flexDirection="column"
57
- height="367px"
58
- >
59
- {initialLineVerticalState.map(({ id, url }) => (
60
- <Draggable.Item dragId={id}
61
- key={id}
62
- marginBottom="sm"
63
- >
64
- <Image alt={id}
65
- size="md"
66
- url={url}
67
- />
68
- </Draggable.Item>
69
- ))}
70
- </Flex>
71
- </Draggable.Container>
72
- </DraggableProvider>
73
- <Caption marginBottom="xs"
74
- marginTop="xl"
75
- text="Horizontal"
76
- />
77
- <Flex>
78
- <DraggableProvider
79
- dropZone={{ type: "line", direction: "horizontal" }}
80
- initialItems={dataLineHorizontal}
81
- onReorder={(items) => setInitialLineHorizontalState(items)}
82
- >
83
- <Draggable.Container
84
- htmlOptions={{style:{ width: "285px"}}}
85
- {...props}
86
- >
87
- <Flex alignItems="stretch"
88
- flexDirection="row"
89
- height="110px"
90
- >
91
- {initialLineHorizontalState.map(({ id, url }) => (
92
- <Draggable.Item dragId={id}
93
- key={id}
94
- marginRight="sm"
95
- >
96
- <Image alt={id}
97
- size="md"
98
- url={url}
99
- />
100
- </Draggable.Item>
101
- ))}
102
- </Flex>
103
- </Draggable.Container>
104
- </DraggableProvider>
105
- </Flex>
106
- </>
107
- );
108
- };
109
-
110
- export default DraggableDropZones;
@@ -1,5 +0,0 @@
1
- When using the "line" style, make sure to set the appropriate `direction` attribute within the `dropZone` prop based on the orientation of your draggable view. By default, this is set to "vertical," but it can also be adjusted to "horizontal." Note that the direction attribute only applies to the "line" style and does not affect other drop zone styles. The default `color` for "line" is "primary" and "purple" is the only alternative color option.
2
-
3
- The length of the line is calculated based off of the width (for "vertical") or height (for "horizontal") of the parent container holding the draggable items.
4
-
5
- Additionally, if the parent container of the `DraggableProvider`/`DraggableContainer` (or a subcontainer within) does not have a set height (for "vertical") or width (for "horizontal"), like the [Draggable Drop Zones doc example](https://playbook.powerapp.cloud/kits/draggable/react#draggable-drop-zones) does, elements on the page may jump up (for "vertical") or to the left (for "horizontal") when an item is actively being dragged. To prevent this, give a parent element a fixed height (for "vertical") or width (for "horizontal") as demonstrated in this doc example.