playbook_ui_docs 13.29.0.pre.alpha.testingcollapsibleissue3052 → 13.30.0.pre.alpha.PBNTR353draggablev53136

Sign up to get free protection for your applications and to get access to all the features.
Files changed (28) hide show
  1. checksums.yaml +4 -4
  2. data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_horizontal.html.erb +58 -0
  3. data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_horizontal.jsx +68 -0
  4. data/app/pb_kits/playbook/pb_bar_graph/docs/example.yml +2 -0
  5. data/app/pb_kits/playbook/pb_bar_graph/docs/index.js +1 -0
  6. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_default.jsx +3 -2
  7. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_default.md +2 -2
  8. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers.jsx +13 -8
  9. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_multiple_containers.md +1 -0
  10. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards.jsx +23 -35
  11. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_cards.md +5 -0
  12. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list.jsx +7 -7
  13. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_list.md +7 -1
  14. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list.jsx +11 -9
  15. data/app/pb_kits/playbook/pb_draggable/docs/_draggable_with_selectable_list.md +7 -0
  16. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_default.html.erb +24 -0
  17. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_default.jsx +40 -0
  18. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_default.md +7 -0
  19. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_multi_directional.html.erb +11 -0
  20. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_multi_directional.jsx +36 -0
  21. data/app/pb_kits/playbook/pb_overlay/docs/_overlay_multi_directional.md +5 -0
  22. data/app/pb_kits/playbook/pb_overlay/docs/example.yml +8 -0
  23. data/app/pb_kits/playbook/pb_overlay/docs/index.js +2 -0
  24. data/app/pb_kits/playbook/pb_table/docs/_table_alignment_column_rails.html.erb +32 -33
  25. data/dist/app/components/playbook/pb_docs/kit_example.rb +19 -3
  26. data/dist/menu.yml +5 -1
  27. data/dist/playbook-doc.js +9 -9
  28. metadata +15 -2
@@ -0,0 +1,8 @@
1
+ examples:
2
+ react:
3
+ - overlay_default: Default
4
+ - overlay_multi_directional: Multi-directional
5
+
6
+ rails:
7
+ - overlay_default: Default
8
+ - overlay_multi_directional: Multi-directional
@@ -0,0 +1,2 @@
1
+ export { default as OverlayDefault } from './_overlay_default.jsx'
2
+ export { default as OverlayMultiDirectional } from './_overlay_multi_directional.jsx'
@@ -1,34 +1,33 @@
1
- <%= pb_rails("table") do %>
2
- <thead>
3
- <tr>
4
- <th>Column 1</th>
5
- <th>Column 2</th>
6
- <th>Column 3</th>
7
- <th align="center">Rating</th>
8
- <th align="right">Money</th>
9
- </tr>
10
- </thead>
11
- <tbody>
12
- <tr>
13
- <td>Value 1</td>
14
- <td>Value 2</td>
15
- <td>Value 3</td>
16
- <td align="center">3</td>
17
- <td align="right">$57.32</td>
18
- </tr>
19
- <tr>
20
- <td>Value 1</td>
21
- <td>Value 2</td>
22
- <td>Value 3</td>
23
- <td align="center">2</td>
24
- <td align="right">$5,657.08</td>
25
- </tr>
26
- <tr>
27
- <td>Value 1</td>
28
- <td>Value 2</td>
29
- <td>Value 3</td>
30
- <td align="center">4</td>
31
- <td align="right">$358.77</td>
32
- </tr>
33
- </tbody>
1
+ <%= pb_rails("table") do %> <%= pb_rails("table/table_head") do %>
2
+ <%= pb_rails("table/table_row") do %>
3
+ <%= pb_rails("table/table_header", props: { text: "Column 1"}) %>
4
+ <%= pb_rails("table/table_header", props: { text: "Column 2"}) %>
5
+ <%= pb_rails("table/table_header", props: { text: "Column 3"}) %>
6
+ <%= pb_rails("table/table_header", props: { text: "Rating", text_align: "center" }) %>
7
+ <%= pb_rails("table/table_header", props: { text: "Money", text_align: "right" }) %>
8
+ <% end %>
9
+ <% end %>
10
+ <%= pb_rails("table/table_body") do %>
11
+ <%= pb_rails("table/table_row") do %>
12
+ <%= pb_rails("table/table_cell", props: { text: "Value 1"}) %>
13
+ <%= pb_rails("table/table_cell", props: { text: "Value 2"}) %>
14
+ <%= pb_rails("table/table_cell", props: { text: "Value 3"}) %>
15
+ <%= pb_rails("table/table_cell", props: { text: "3", text_align: "center" }) %>
16
+ <%= pb_rails("table/table_cell", props: { text: "$57.32", text_align: "right" }) %>
17
+ <% end %>
18
+ <%= pb_rails("table/table_row") do %>
19
+ <%= pb_rails("table/table_cell", props: { text: "Value 1"}) %>
20
+ <%= pb_rails("table/table_cell", props: { text: "Value 2"}) %>
21
+ <%= pb_rails("table/table_cell", props: { text: "Value 3"}) %>
22
+ <%= pb_rails("table/table_cell", props: { text: "2", text_align: "center" }) %>
23
+ <%= pb_rails("table/table_cell", props: { text: "$5,657.08", text_align: "right" }) %>
24
+ <% end %>
25
+ <%= pb_rails("table/table_row") do %>
26
+ <%= pb_rails("table/table_cell", props: { text: "Value 1"}) %>
27
+ <%= pb_rails("table/table_cell", props: { text: "Value 2"}) %>
28
+ <%= pb_rails("table/table_cell", props: { text: "Value 3"}) %>
29
+ <%= pb_rails("table/table_cell", props: { text: "4", text_align: "center" }) %>
30
+ <%= pb_rails("table/table_cell", props: { text: "$358.77", text_align: "right" }) %>
31
+ <% end %>
32
+ <% end %>
34
33
  <% end %>
@@ -67,9 +67,25 @@ module Playbook
67
67
  stringified_code.gsub(" {...props}", "")
68
68
  end
69
69
 
70
- def read_kit_file(folder, *args)
71
- path = ::Playbook.kit_path(kit, folder, *args)
72
- path.exist? ? path.read : ""
70
+ def read_kit_file(folder, file_name)
71
+ name_array = file_name.split(".")
72
+ path = ::Playbook.kit_path(kit, folder, file_name)
73
+ if name_array[1] != "md"
74
+ (path.exist? ? path.read : "")
75
+ else
76
+ if path.exist?
77
+ path.read
78
+ elsif type == "rails"
79
+ name_array[0] += "_rails"
80
+ file_name = name_array.join(".")
81
+ path = ::Playbook.kit_path(kit, folder, file_name)
82
+ elsif type == "react"
83
+ name_array[0] += "_react"
84
+ file_name = name_array.join(".")
85
+ path = ::Playbook.kit_path(kit, folder, file_name)
86
+ end
87
+ (path.exist? ? path.read : "")
88
+ end
73
89
  end
74
90
  end
75
91
  end
data/dist/menu.yml CHANGED
@@ -352,6 +352,9 @@ kits:
352
352
  platforms: *web
353
353
  description:
354
354
  status: "stable"
355
+ - name: "overlay"
356
+ platforms: *web
357
+ status: "stable"
355
358
  - name: "draggable"
356
359
  platforms: *react_only
357
360
  description:
@@ -467,4 +470,5 @@ kits:
467
470
  status: "stable"
468
471
  - name: "user"
469
472
  platforms: *web
470
- description: This kit was created for having a systematic way of displaying users with avatar, titles, name and territory. This is a versatile kit with features than can be added to display more info.
473
+ description: This kit was created for having a systematic way of displaying users with avatar, titles, name and territory. This is a versatile kit with features than can be added to display more info.
474
+ status: "stable"