playbook_ui_docs 14.12.0.pre.rc.6 → 14.12.0.pre.rc.8

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8124c32ee229b52c472ee92f31216553fb2e45b3a9780f4f0ce0ab339df3660a
4
- data.tar.gz: b5f5b58a1dd5b22b8371614ec2b3cc836db6177aba7544e7ced3acca19db23b3
3
+ metadata.gz: 7bac3f7ae5ae1fce63f0411ada68213712f711b8b2feddaaf6934ee54dc8ec96
4
+ data.tar.gz: 2bdf375e5cf0f1d77d11e8bb70d3d9a2d43359cf076658d5fb1198e7f62174c6
5
5
  SHA512:
6
- metadata.gz: 761a986bea043638a725517d6d9e8dfb309f9a4f74fc983b8d68aa39ea466c044e40da2b9c73704d0a7141955454b4e4f3ab29995a07b2b439856d4d6a6829f2
7
- data.tar.gz: a06a8f7377ad644ded5d175f6f2405577118821519ccf96bf7ffa63f3ee96859ff0940c581adc043e1938770cc9ea584550414000b4ad3ee26a17423202a17bb
6
+ metadata.gz: ffccf0d3663a894ce74e7b80d64747b2adb3caf82d10991442cdae61c9a9348911faca149e85ebcbf852c1626c7082e50a780f748c3ee38745ab2424b3b13af3
7
+ data.tar.gz: e6687d18bd8524dc4207f8abf93eb2124cc7f3a4ddaf0844bace94810f79f34e7209bd97fd06b6ab94310634e998dd50f8703f2f7e8feda6fa0cb4860179cdf7
@@ -2,4 +2,4 @@ The `defaultDate`/`default_date` prop has a null or empty string value by defaul
2
2
 
3
3
  If you use a Date object without UTC time standardization the Date Picker kit may misinterpret that date as yesterdays date (consequence of timezone differentials and the Javascript Date Object constructor). See [this GitHub issue for more information](https://github.com/powerhome/playbook/issues/1167) and the anti-pattern examples below.
4
4
 
5
-
5
+ You can leverage the `defaultDate`/`default_date` prop with custom logic in your filter or controller files where the determination of the default value changes based on user interaction. The page can load with an initial default date picker value or placeholder text, then after filter submission save the submitted values as the "new default" (via state or params).
@@ -6,14 +6,8 @@
6
6
 
7
7
  ] %>
8
8
 
9
- <%= pb_rails("draggable", props: {initial_items: initial_items}) do %>
10
- <%= pb_rails("draggable/draggable_container") do %>
11
- <%= pb_rails("list", props: {ordered: false}) do %>
12
- <% initial_items.each do |item| %>
13
- <%= pb_rails("draggable/draggable_item", props:{drag_id: item[:id]}) do %>
14
- <%= pb_rails("list/item") do %><%= item[:name] %><% end %>
15
- <% end %>
16
- <% end %>
17
- <% end %>
9
+ <%= pb_rails("list", props: { enable_drag: true, items: initial_items }) do %>
10
+ <% initial_items.each do |item| %>
11
+ <%= pb_rails("list/item", props:{drag_id: item[:id]}) do %><%= item[:name] %><% end %>
18
12
  <% end %>
19
13
  <% end %>
@@ -0,0 +1,5 @@
1
+ For a simplified version of the Draggable API for the List kit, you can do the following:
2
+
3
+ The List kit is optimized to work with the draggable kit. To enable drag, use the `enable_drag` prop on List kit with an array of the included items AND `drag_id` prop on ListItems. You will also need to include the `items` prop containing your array of listed items for the Draggable API.
4
+
5
+ An additional optional boolean prop (set to true by default) of `drag_handle` is also available on ListItem kit to show the drag handle icon.
@@ -0,0 +1,74 @@
1
+ <%= pb_rails("table", props: { size: "md", responsive: "scroll", sticky_left_column: ["a"], sticky_right_column: ["b"] }) do %>
2
+ <thead>
3
+ <tr>
4
+ <th id="a">Column 1</th>
5
+ <th>Column 2</th>
6
+ <th>Column 3</th>
7
+ <th>Column 4</th>
8
+ <th>Column 5</th>
9
+ <th>Column 6</th>
10
+ <th>Column 7</th>
11
+ <th>Column 8</th>
12
+ <th>Column 9</th>
13
+ <th>Column 10</th>
14
+ <th>Column 11</th>
15
+ <th>Column 12</th>
16
+ <th>Column 13</th>
17
+ <th>Column 14</th>
18
+ <th id="b">Column 15</th>
19
+ </tr>
20
+ </thead>
21
+ <tbody>
22
+ <tr>
23
+ <td id="a">Value 1</td>
24
+ <td>Value 2</td>
25
+ <td>Value 3</td>
26
+ <td>Value 4</td>
27
+ <td>Value 5</td>
28
+ <td>Value 6</td>
29
+ <td>Value 7</td>
30
+ <td>Value 8</td>
31
+ <td>Value 9</td>
32
+ <td>Value 10</td>
33
+ <td>Value 11</td>
34
+ <td>Value 12</td>
35
+ <td>Value 13</td>
36
+ <td>Value 14</td>
37
+ <td id="b">Value 15</td>
38
+ </tr>
39
+ <tr>
40
+ <td id="a">Value 1</td>
41
+ <td>Value 2</td>
42
+ <td>Value 3</td>
43
+ <td>Value 4</td>
44
+ <td>Value 5</td>
45
+ <td>Value 6</td>
46
+ <td>Value 7</td>
47
+ <td>Value 8</td>
48
+ <td>Value 9</td>
49
+ <td>Value 10</td>
50
+ <td>Value 11</td>
51
+ <td>Value 12</td>
52
+ <td>Value 13</td>
53
+ <td>Value 14</td>
54
+ <td id="b">Value 15</td>
55
+ </tr>
56
+ <tr>
57
+ <td id="a">Value 1</td>
58
+ <td>Value 2</td>
59
+ <td>Value 3</td>
60
+ <td>Value 4</td>
61
+ <td>Value 5</td>
62
+ <td>Value 6</td>
63
+ <td>Value 7</td>
64
+ <td>Value 8</td>
65
+ <td>Value 9</td>
66
+ <td>Value 10</td>
67
+ <td>Value 11</td>
68
+ <td>Value 12</td>
69
+ <td>Value 13</td>
70
+ <td>Value 14</td>
71
+ <td id="b">Value 15</td>
72
+ </tr>
73
+ </tbody>
74
+ <% end %>
@@ -0,0 +1,3 @@
1
+ The `sticky_left_column` and `sticky_right_column` props can be used together on the same table as needed.
2
+
3
+ Please ensure that unique ids are used for all columns across multiple tables. Using the same columns ids on multiple tables can lead to issues when using props.
@@ -1,3 +1,3 @@
1
- The `stickyLeftColumn` prop expects an array of the column ids you want to be sticky. Make sure to add the corresponding id to the `<th>` and `<td>`.
1
+ The `sticky_left_column` prop expects an array of the column ids you want to be sticky. Make sure to add the corresponding id to the `<th>` and `<td>`.
2
2
 
3
- Please ensure that unique ids are used for all columns across multiple tables. Using the same columns ids on multiple tables can lead to issues when using the `stickyLeftColumn`.
3
+ Please ensure that unique ids are used for all columns across multiple tables. Using the same columns ids on multiple tables can lead to issues when using the `sticky_left_column`.
@@ -0,0 +1,74 @@
1
+ <%= pb_rails("table", props: { size: "md", responsive: "scroll", sticky_right_column: ["13", "14", "15"] }) do %>
2
+ <thead>
3
+ <tr>
4
+ <th>Column 1</th>
5
+ <th>Column 2</th>
6
+ <th>Column 3</th>
7
+ <th>Column 4</th>
8
+ <th>Column 5</th>
9
+ <th>Column 6</th>
10
+ <th>Column 7</th>
11
+ <th>Column 8</th>
12
+ <th>Column 9</th>
13
+ <th>Column 10</th>
14
+ <th>Column 11</th>
15
+ <th>Column 12</th>
16
+ <th id="13">Column 13</th>
17
+ <th id="14">Column 14</th>
18
+ <th id="15">Column 15</th>
19
+ </tr>
20
+ </thead>
21
+ <tbody>
22
+ <tr>
23
+ <td>Value 1</td>
24
+ <td>Value 2</td>
25
+ <td>Value 3</td>
26
+ <td>Value 4</td>
27
+ <td>Value 5</td>
28
+ <td>Value 6</td>
29
+ <td>Value 7</td>
30
+ <td>Value 8</td>
31
+ <td>Value 9</td>
32
+ <td>Value 10</td>
33
+ <td>Value 11</td>
34
+ <td>Value 12</td>
35
+ <td id="13">Value 13</td>
36
+ <td id="14">Value 14</td>
37
+ <td id="15">Value 15</td>
38
+ </tr>
39
+ <tr>
40
+ <td>Value 1</td>
41
+ <td>Value 2</td>
42
+ <td>Value 3</td>
43
+ <td>Value 4</td>
44
+ <td>Value 5</td>
45
+ <td>Value 6</td>
46
+ <td>Value 7</td>
47
+ <td>Value 8</td>
48
+ <td>Value 9</td>
49
+ <td>Value 10</td>
50
+ <td>Value 11</td>
51
+ <td>Value 12</td>
52
+ <td id="13">Value 13</td>
53
+ <td id="14">Value 14</td>
54
+ <td id="15">Value 15</td>
55
+ </tr>
56
+ <tr>
57
+ <td>Value 1</td>
58
+ <td>Value 2</td>
59
+ <td>Value 3</td>
60
+ <td>Value 4</td>
61
+ <td>Value 5</td>
62
+ <td>Value 6</td>
63
+ <td>Value 7</td>
64
+ <td>Value 8</td>
65
+ <td>Value 9</td>
66
+ <td>Value 10</td>
67
+ <td>Value 11</td>
68
+ <td>Value 12</td>
69
+ <td id="13">Value 13</td>
70
+ <td id="14">Value 14</td>
71
+ <td id="15">Value 15</td>
72
+ </tr>
73
+ </tbody>
74
+ <% end %>
@@ -0,0 +1,3 @@
1
+ The `sticky_right_column` prop works in the same way as the above `sticky_left_column` prop. It expects an array of the column ids you want to be sticky. Make sure to add the corresponding id to the `<th>` and `<td>`.
2
+
3
+ Please ensure that unique ids are used for all columns across multiple tables. Using the same columns ids on multiple tables can lead to issues when using the `sticky_right_column` prop.
@@ -5,6 +5,8 @@ examples:
5
5
  - table_lg: Large
6
6
  - table_sticky: Sticky Header
7
7
  - table_sticky_left_columns: Sticky Left Column
8
+ - table_sticky_right_columns: Sticky Right Column
9
+ - table_sticky_columns: Sticky Left and Right Columns
8
10
  - table_header: Table Header
9
11
  - table_alignment_row_rails: Row Alignment
10
12
  - table_alignment_column_rails: Cell Alignment