playbook_ui 15.2.0 → 15.3.0.pre.alpha.PLAY2565formkitsubmitfix11681
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/_playbook.scss +5 -5
- data/app/pb_kits/playbook/pb_advanced_table/advanced_table.html.erb +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_background_control_rails.html.erb +39 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_background_control_rails.md +1 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta.md +3 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta_sort.html.erb +3 -3
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta_subrow_headers.html.erb +3 -3
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_collapsible_trail_rails.html.erb +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling.md +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling_column_headers_rails.html.erb +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling_rails.html.erb +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling_rails.md +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_padding_control_per_row_rails.html.erb +51 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_padding_control_per_row_rails.md +1 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_padding_control_rails.html.erb +40 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_padding_control_rails.md +1 -0
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_row_styling_rails.md +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_row_styling_react.md +1 -1
- data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_selectable_rows_rails.html.erb +2 -2
- data/app/pb_kits/playbook/pb_advanced_table/docs/example.yml +3 -0
- data/app/pb_kits/playbook/pb_advanced_table/index.js +5 -1
- data/app/pb_kits/playbook/pb_advanced_table/table_body.rb +6 -6
- data/app/pb_kits/playbook/pb_advanced_table/table_header.rb +6 -6
- data/app/pb_kits/playbook/pb_advanced_table/table_row.html.erb +3 -2
- data/app/pb_kits/playbook/pb_advanced_table/table_row.rb +49 -5
- data/app/pb_kits/playbook/pb_bread_crumbs/docs/_bread_crumbs_default.html.erb +4 -4
- data/app/pb_kits/playbook/pb_bread_crumbs/docs/_bread_crumbs_default.jsx +4 -0
- data/app/pb_kits/playbook/pb_button/_button.scss +6 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_loading.html.erb +7 -3
- data/app/pb_kits/playbook/pb_button/docs/_button_loading.jsx +29 -0
- data/app/pb_kits/playbook/pb_date_picker/docs/_date_picker_range_pattern.jsx +1 -1
- data/app/pb_kits/playbook/pb_draggable/_draggable.scss +8 -0
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/_fixed_confirmation_toast.scss +0 -1
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/_fixed_confirmation_toast.tsx +5 -3
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/docs/_description.md +2 -0
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/fixed_confirmation_toast.rb +4 -1
- data/app/pb_kits/playbook/pb_fixed_confirmation_toast/fixed_confirmation_toast.test.js +10 -0
- data/app/pb_kits/playbook/pb_form/docs/_form_form_with_loading.html.erb +1 -1
- data/app/pb_kits/playbook/pb_form/docs/_form_form_with_validate.html.erb +1 -1
- data/app/pb_kits/playbook/pb_form/formHelper.js +1 -1
- data/app/pb_kits/playbook/pb_pb_bar_graph/_pb_bar_graph.tsx +8 -6
- data/app/pb_kits/playbook/pb_pb_bar_graph/docs/_description.md +3 -0
- data/app/pb_kits/playbook/pb_pb_bar_graph/pb_bar_graph.rb +7 -10
- data/app/pb_kits/playbook/pb_pb_bar_graph/pbbargraph.test.jsx +73 -1
- data/app/pb_kits/playbook/pb_pb_circle_chart/_pb_circle_chart.tsx +1 -1
- data/app/pb_kits/playbook/pb_pb_circle_chart/docs/_description.md +3 -0
- data/app/pb_kits/playbook/pb_pb_circle_chart/pb_circle_chart.rb +7 -10
- data/app/pb_kits/playbook/pb_pb_circle_chart/pb_circle_chart.test.jsx +47 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/_pb_gauge_chart.scss +3 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/_pb_gauge_chart.tsx +69 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_description.md +3 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_color.html.erb +12 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_color.jsx +24 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_color.md +5 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_complex.html.erb +45 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_complex.jsx +119 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_complex.md +1 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_default.html.erb +5 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_default.jsx +17 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_disable_animation.html.erb +12 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_disable_animation.jsx +24 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_full_circle.html.erb +23 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_full_circle.jsx +37 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_height.html.erb +40 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_height.jsx +56 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_live_data.jsx +64 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_min_max.html.erb +27 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_min_max.jsx +40 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_min_max.md +1 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_sizing.html.erb +19 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_sizing.jsx +65 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_sizing.md +3 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_title.html.erb +14 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_title.jsx +27 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_units.html.erb +39 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_units.jsx +58 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/_pb_gauge_chart_units.md +1 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/example.yml +29 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/docs/index.js +11 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/pbGaugeGraphTheme.ts +91 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/pb_gauge_chart.html.erb +1 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/pb_gauge_chart.rb +25 -0
- data/app/pb_kits/playbook/pb_pb_gauge_chart/pb_gauge_chart.test.jsx +80 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/_pb_line_graph.scss +3 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/_pb_line_graph.tsx +61 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_description.md +3 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_colors.html.erb +34 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_colors.jsx +52 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_colors.md +5 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_default.html.erb +34 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_default.jsx +45 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_height.html.erb +47 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_height.jsx +64 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_height.md +3 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend.html.erb +24 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend.jsx +37 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend_nonclickable.html.erb +39 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend_nonclickable.jsx +45 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend_position.html.erb +86 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend_position.jsx +116 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/_pb_line_graph_legend_position.md +11 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/example.yml +20 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/docs/index.js +6 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/pbLineGraphTheme.ts +125 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/pb_line_graph.html.erb +1 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/pb_line_graph.rb +25 -0
- data/app/pb_kits/playbook/pb_pb_line_graph/pb_line_graph.test.jsx +110 -0
- data/app/pb_kits/playbook/pb_phone_number_input/_phone_number_input.tsx +130 -28
- data/app/pb_kits/playbook/pb_rich_text_editor/TipTap/Toolbar.tsx +41 -2
- data/app/pb_kits/playbook/pb_rich_text_editor/TipTap/ToolbarDropdown.tsx +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/_rich_text_editor.tsx +60 -20
- data/app/pb_kits/playbook/pb_rich_text_editor/_tiptap_styles.scss +36 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_attributes.jsx +38 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_attributes.md +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_focus.jsx +34 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_focus.md +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_inline.jsx +37 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_inline.md +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_simple.jsx +37 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_sticky.jsx +38 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_sticky.md +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_templates.jsx +69 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/_rich_text_editor_advanced_templates.md +1 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/example.yml +8 -2
- data/app/pb_kits/playbook/pb_rich_text_editor/docs/index.js +6 -0
- data/app/pb_kits/playbook/pb_rich_text_editor/rich_text_editor.test.js +127 -1
- data/app/pb_kits/playbook/pb_timeline/_timeline.scss +250 -233
- data/app/pb_kits/playbook/pb_timeline/_timeline.tsx +1 -1
- data/app/pb_kits/playbook/pb_timeline/timeline.test.js +2 -2
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.test.jsx +35 -1
- data/app/pb_kits/playbook/pb_typeahead/_typeahead.tsx +71 -2
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_default_options.html.erb +36 -0
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_default_options.md +1 -0
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_default_value.jsx +41 -0
- data/app/pb_kits/playbook/pb_typeahead/docs/_typeahead_default_value.md +1 -0
- data/app/pb_kits/playbook/pb_typeahead/docs/example.yml +2 -0
- data/app/pb_kits/playbook/pb_typeahead/docs/index.js +1 -0
- data/app/pb_kits/playbook/tokens/_positioning.scss +1 -0
- data/app/pb_kits/playbook/utilities/_positioning.scss +6 -1
- data/app/pb_kits/playbook/utilities/globalProps.ts +3 -1
- data/dist/chunks/{_line_graph-ByLTvO72.js → _line_graph-h5H-imfn.js} +1 -1
- data/dist/chunks/_typeahead-U8AjZIIW.js +6 -0
- data/dist/chunks/{_weekday_stacked-CB1Sm0pQ.js → _weekday_stacked-CbCUYuuZ.js} +2 -2
- data/dist/chunks/{lib-izYrkvOQ.js → lib-CGxXTQ75.js} +2 -2
- data/dist/chunks/{pb_form_validation-Cah5Z5J3.js → pb_form_validation-DebqlUKZ.js} +1 -1
- data/dist/chunks/vendor.js +1 -1
- data/dist/menu.yml +12 -0
- data/dist/playbook-doc.js +2 -2
- 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/pb_forms_helper.rb +7 -6
- data/lib/playbook/version.rb +2 -2
- data/lib/playbook/z_index.rb +1 -1
- metadata +89 -7
- data/dist/chunks/_typeahead-DXZQU3hC.js +0 -6
    
        checksums.yaml
    CHANGED
    
    | @@ -1,7 +1,7 @@ | |
| 1 1 | 
             
            ---
         | 
| 2 2 | 
             
            SHA256:
         | 
| 3 | 
            -
              metadata.gz:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: e57165e0f6855d1e877e88b67b0cfc62dffcca56c75494c4919a2774443a3f4e
         | 
| 4 | 
            +
              data.tar.gz: c13a71137883d0c2277e488a8a0163f88768e01a22d75c9d0f1bcd157ca473b9
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: e40cbc1a718b7157b85199fbd02852055a6dfa954d351af3a3299a84311b3185b8bbc93de30b9000b2161d97ae1bdd79f8a519ce3524d9907e506b095ed3c9b7
         | 
| 7 | 
            +
              data.tar.gz: e06abbce30f98797e15dc84498c72d3d370275df49cb93f490fa8a9cdda3cc5844efe471a2fdb37ad969db0801bc6f6fb6c0f476204eae726b50b30042f1f296
         | 
| @@ -1,6 +1,4 @@ | |
| 1 1 |  | 
| 2 | 
            -
             | 
| 3 | 
            -
             | 
| 4 2 | 
             
            @import 'pb_advanced_table/advanced_table';
         | 
| 5 3 | 
             
            @import 'pb_avatar/avatar';
         | 
| 6 4 | 
             
            @import 'pb_background/background';
         | 
| @@ -33,6 +31,7 @@ | |
| 33 31 | 
             
            @import 'pb_distribution_bar/distribution_bar';
         | 
| 34 32 | 
             
            @import 'pb_draggable/draggable';
         | 
| 35 33 | 
             
            @import 'pb_dropdown/dropdown';
         | 
| 34 | 
            +
            @import 'pb_empty_state/empty_state';
         | 
| 36 35 | 
             
            @import 'pb_file_upload/file_upload';
         | 
| 37 36 | 
             
            @import 'pb_filter/filter';
         | 
| 38 37 | 
             
            @import 'pb_fixed_confirmation_toast/fixed_confirmation_toast';
         | 
| @@ -70,6 +69,10 @@ | |
| 70 69 | 
             
            @import 'pb_overlay/overlay';
         | 
| 71 70 | 
             
            @import 'pb_pagination/pagination';
         | 
| 72 71 | 
             
            @import 'pb_passphrase/passphrase';
         | 
| 72 | 
            +
            @import 'pb_pb_bar_graph/pb_bar_graph';
         | 
| 73 | 
            +
            @import 'pb_pb_circle_chart/pb_circle_chart';
         | 
| 74 | 
            +
            @import 'pb_pb_gauge_chart/pb_gauge_chart';
         | 
| 75 | 
            +
            @import 'pb_pb_line_graph/pb_line_graph';
         | 
| 73 76 | 
             
            @import 'pb_person/person';
         | 
| 74 77 | 
             
            @import 'pb_person_contact/person_contact';
         | 
| 75 78 | 
             
            @import 'pb_phone_number_input/phone_number_input';
         | 
| @@ -108,9 +111,6 @@ | |
| 108 111 | 
             
            @import 'pb_user/user';
         | 
| 109 112 | 
             
            @import 'pb_user_badge/user_badge';
         | 
| 110 113 | 
             
            @import 'pb_weekday_stacked/weekday_stacked';
         | 
| 111 | 
            -
            @import 'pb_empty_state/empty_state';
         | 
| 112 | 
            -
            @import 'pb_pb_bar_graph/pb_bar_graph';
         | 
| 113 | 
            -
            @import 'pb_pb_circle_chart/pb_circle_chart';
         | 
| 114 114 | 
             
            @import 'utilities/mixins';
         | 
| 115 115 | 
             
            @import 'utilities/spacing';
         | 
| 116 116 | 
             
            @import 'utilities/cursor';
         | 
| @@ -11,8 +11,8 @@ | |
| 11 11 | 
             
                <% if content.present? %>
         | 
| 12 12 | 
             
                  <% content.presence %>
         | 
| 13 13 | 
             
                <% else %>
         | 
| 14 | 
            -
                  <%= pb_rails("advanced_table/table_header", props: {  | 
| 15 | 
            -
                  <%= pb_rails("advanced_table/table_body", props: {  | 
| 14 | 
            +
                  <%= pb_rails("advanced_table/table_header", props: { table_id: object.id, column_definitions: object.column_definitions, enable_toggle_expansion: object.enable_toggle_expansion, responsive: object.responsive, loading: object.loading, selectable_rows: object.selectable_rows, show_actions_bar: object.show_actions_bar }) %>
         | 
| 15 | 
            +
                  <%= pb_rails("advanced_table/table_body", props: { table_id: object.id, table_data: object.table_data, column_definitions: object.column_definitions, responsive: object.responsive, loading: object.loading, selectable_rows: object.selectable_rows, enable_toggle_expansion: object.enable_toggle_expansion, row_styling: object.row_styling }) %>
         | 
| 16 16 | 
             
                <% end %>
         | 
| 17 17 | 
             
              <% end %>
         | 
| 18 18 | 
             
            <% end %>
         | 
    
        data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_background_control_rails.html.erb
    ADDED
    
    | @@ -0,0 +1,39 @@ | |
| 1 | 
            +
            <% column_definitions = [
         | 
| 2 | 
            +
                {
         | 
| 3 | 
            +
                  accessor: "year",
         | 
| 4 | 
            +
                  label: "Year",
         | 
| 5 | 
            +
                  cellAccessors: ["quarter", "month", "day"],
         | 
| 6 | 
            +
                },
         | 
| 7 | 
            +
                {
         | 
| 8 | 
            +
                  accessor: "newEnrollments",
         | 
| 9 | 
            +
                  label: "New Enrollments",
         | 
| 10 | 
            +
                  column_styling: { 
         | 
| 11 | 
            +
                    cell_background_color: ->(row) { row[:newEnrollments].to_i > 20 ? "success_secondary" : "warning_secondary" }
         | 
| 12 | 
            +
                  }
         | 
| 13 | 
            +
                },
         | 
| 14 | 
            +
                {
         | 
| 15 | 
            +
                  accessor: "scheduledMeetings",
         | 
| 16 | 
            +
                  label: "Scheduled Meetings",
         | 
| 17 | 
            +
                },
         | 
| 18 | 
            +
                {
         | 
| 19 | 
            +
                  accessor: "attendanceRate",
         | 
| 20 | 
            +
                  label: "Attendance Rate",
         | 
| 21 | 
            +
                },
         | 
| 22 | 
            +
                {
         | 
| 23 | 
            +
                  accessor: "completedClasses",
         | 
| 24 | 
            +
                  label: "Completed Classes",
         | 
| 25 | 
            +
                },
         | 
| 26 | 
            +
                {
         | 
| 27 | 
            +
                  accessor: "classCompletionRate",
         | 
| 28 | 
            +
                  label: "Class Completion Rate",
         | 
| 29 | 
            +
                },
         | 
| 30 | 
            +
                {
         | 
| 31 | 
            +
                  accessor: "graduatedStudents",
         | 
| 32 | 
            +
                  label: "Graduated Students",
         | 
| 33 | 
            +
                }
         | 
| 34 | 
            +
            ] %>
         | 
| 35 | 
            +
             | 
| 36 | 
            +
            <%= pb_rails("advanced_table", props: { id: "background-control", table_data: @table_data, column_definitions: column_definitions }) do %>
         | 
| 37 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "background-control", column_definitions: column_definitions }) %>
         | 
| 38 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "background-control", table_data: @table_data, column_definitions: column_definitions }) %>
         | 
| 39 | 
            +
            <% end %>
         | 
| @@ -0,0 +1 @@ | |
| 1 | 
            +
            `column_styling` can also be used to control the background color on all cells in a given column via the use of the `cell_background_color` key/value pair. Use `cell_background_color` to achieve custom background colors for individual cells as seen here.
         | 
| @@ -2,7 +2,9 @@ The AdvancedTable kit accepts tree data and automatically renders expansion cont | |
| 2 2 |  | 
| 3 3 | 
             
            ### id
         | 
| 4 4 |  | 
| 5 | 
            -
            A unique `id` is required to allow the table functionality to work properly. Without it, certain functions like the action bar will not be able to properly reference the correct table.
         | 
| 5 | 
            +
            A unique `id` is required to allow the table functionality to work properly. Without it, certain functions like the action bar, expand/collapse caching, or selectable rows will not be able to properly reference the correct table.
         | 
| 6 | 
            +
             | 
| 7 | 
            +
            You must also set `table_id` when using subcomponents like `table_header` or `table_body`.
         | 
| 6 8 |  | 
| 7 9 | 
             
            ### table_data
         | 
| 8 10 |  | 
| @@ -51,7 +51,7 @@ | |
| 51 51 | 
             
              ]
         | 
| 52 52 | 
             
            %>
         | 
| 53 53 |  | 
| 54 | 
            -
            <%= pb_rails("advanced_table", props: { table_data: @table_data, column_definitions: column_definitions, id: "beta_sort" }) do %>
         | 
| 55 | 
            -
              <%= pb_rails("advanced_table/table_header", props: { column_definitions: column_definitions }) %>
         | 
| 56 | 
            -
              <%= pb_rails("advanced_table/table_body", props: {  | 
| 54 | 
            +
            <%= pb_rails("advanced_table", props: { id: "sort", table_data: @table_data, column_definitions: column_definitions, id: "beta_sort" }) do %>
         | 
| 55 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "sort", column_definitions: column_definitions }) %>
         | 
| 56 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "sort", table_data: @table_data, column_definitions: column_definitions, enable_toggle_expansion: "all" }) %>
         | 
| 57 57 | 
             
            <% end %>
         | 
    
        data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_beta_subrow_headers.html.erb
    CHANGED
    
    | @@ -34,7 +34,7 @@ | |
| 34 34 | 
             
              subrow_headers = ["Quarter", "Month", "Day"]
         | 
| 35 35 | 
             
            %>
         | 
| 36 36 |  | 
| 37 | 
            -
            <%= pb_rails("advanced_table", props: { table_data: @table_data, column_definitions: column_definitions, id: "test_table" }) do %>
         | 
| 38 | 
            -
              <%= pb_rails("advanced_table/table_header", props: { column_definitions: column_definitions }) %>
         | 
| 39 | 
            -
              <%= pb_rails("advanced_table/table_body", props: {  | 
| 37 | 
            +
            <%= pb_rails("advanced_table", props: { id: "subrow-headers", table_data: @table_data, column_definitions: column_definitions, id: "test_table" }) do %>
         | 
| 38 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "subrow-headers", column_definitions: column_definitions }) %>
         | 
| 39 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "subrow-headers", table_data: @table_data, column_definitions: column_definitions, subrow_headers: subrow_headers, enable_toggle_expansion: "all" }) %>
         | 
| 40 40 | 
             
            <% end %>
         | 
    
        data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_collapsible_trail_rails.html.erb
    CHANGED
    
    | @@ -31,6 +31,6 @@ | |
| 31 31 | 
             
            ] %>
         | 
| 32 32 |  | 
| 33 33 | 
             
            <%= pb_rails("advanced_table", props: { id: "collapsible_trail", table_data: @table_data, column_definitions: column_definitions }) do %>
         | 
| 34 | 
            -
              <%= pb_rails("advanced_table/table_header", props: { column_definitions: column_definitions }) %>
         | 
| 35 | 
            -
              <%= pb_rails("advanced_table/table_body", props: { table_data: @table_data, column_definitions: column_definitions, collapsible_trail: false }) %>
         | 
| 34 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "collapsible_trail", column_definitions: column_definitions }) %>
         | 
| 35 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "collapsible_trail", table_data: @table_data, column_definitions: column_definitions, collapsible_trail: false }) %>
         | 
| 36 36 | 
             
            <% end %>
         | 
| @@ -1,4 +1,4 @@ | |
| 1 | 
            -
            The `columnStyling` prop is an optional item that can be used within `columnDefinitions` as shown in the code snippet below. It is an object that has  | 
| 1 | 
            +
            The `columnStyling` prop is an optional item that can be used within `columnDefinitions` as shown in the code snippet below. It is an object that has several optional key/value pairs, this doc example highlights the following:
         | 
| 2 2 |  | 
| 3 3 | 
             
            1) `headerAlignment`: This will allow you to control alignment of header content which is set to right aligned by default. you can set this to `left`, `right` or `center`.
         | 
| 4 4 |  | 
| @@ -58,6 +58,6 @@ | |
| 58 58 | 
             
            ] %>
         | 
| 59 59 |  | 
| 60 60 | 
             
            <%= pb_rails("advanced_table", props: { id: "column-styling-multi", table_data: @table_data, column_definitions: column_definitions }) do %>
         | 
| 61 | 
            -
              <%= pb_rails("advanced_table/table_header", props: { column_definitions: column_definitions }) %>
         | 
| 62 | 
            -
              <%= pb_rails("advanced_table/table_body", props: { table_data: @table_data, column_definitions: column_definitions }) %>
         | 
| 61 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "column-styling-multi", column_definitions: column_definitions }) %>
         | 
| 62 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "column-styling-multi", table_data: @table_data, column_definitions: column_definitions }) %>
         | 
| 63 63 | 
             
            <% end %>
         | 
    
        data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_column_styling_rails.html.erb
    CHANGED
    
    | @@ -33,6 +33,6 @@ | |
| 33 33 | 
             
            ] %>
         | 
| 34 34 |  | 
| 35 35 | 
             
            <%= pb_rails("advanced_table", props: { id: "column-styling", table_data: @table_data, column_definitions: column_definitions }) do %>
         | 
| 36 | 
            -
              <%= pb_rails("advanced_table/table_header", props: { column_definitions: column_definitions }) %>
         | 
| 37 | 
            -
              <%= pb_rails("advanced_table/table_body", props: { table_data: @table_data, column_definitions: column_definitions }) %>
         | 
| 36 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "column-styling", column_definitions: column_definitions }) %>
         | 
| 37 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "column-styling", table_data: @table_data, column_definitions: column_definitions }) %>
         | 
| 38 38 | 
             
            <% end %>
         | 
| @@ -1,4 +1,4 @@ | |
| 1 | 
            -
            The `column_styling` prop is an optional item that can be used within `column_definitions` as shown in the code snippet below. | 
| 1 | 
            +
            The `column_styling` prop is an optional item that can be used within `column_definitions` as shown in the code snippet below.  It is an object that has several optional key/value pairs, this doc example highlights the following:
         | 
| 2 2 |  | 
| 3 3 | 
             
            1) `header_alignment`: This will allow you to control alignment of header content which is set to right aligned by default. you can set this to `left`, `right` or `center`.
         | 
| 4 4 |  | 
| @@ -0,0 +1,51 @@ | |
| 1 | 
            +
            <% column_definitions = [
         | 
| 2 | 
            +
                {
         | 
| 3 | 
            +
                  accessor: "year",
         | 
| 4 | 
            +
                  label: "Year",
         | 
| 5 | 
            +
                  cellAccessors: ["quarter", "month", "day"],
         | 
| 6 | 
            +
                },
         | 
| 7 | 
            +
                {
         | 
| 8 | 
            +
                  accessor: "newEnrollments",
         | 
| 9 | 
            +
                  label: "New Enrollments",
         | 
| 10 | 
            +
                },
         | 
| 11 | 
            +
                {
         | 
| 12 | 
            +
                  accessor: "scheduledMeetings",
         | 
| 13 | 
            +
                  label: "Scheduled Meetings",
         | 
| 14 | 
            +
                },
         | 
| 15 | 
            +
                {
         | 
| 16 | 
            +
                  accessor: "attendanceRate",
         | 
| 17 | 
            +
                  label: "Attendance Rate",
         | 
| 18 | 
            +
                },
         | 
| 19 | 
            +
                {
         | 
| 20 | 
            +
                  accessor: "completedClasses",
         | 
| 21 | 
            +
                  label: "Completed Classes",
         | 
| 22 | 
            +
                },
         | 
| 23 | 
            +
                {
         | 
| 24 | 
            +
                  accessor: "classCompletionRate",
         | 
| 25 | 
            +
                  label: "Class Completion Rate",
         | 
| 26 | 
            +
                },
         | 
| 27 | 
            +
                {
         | 
| 28 | 
            +
                  accessor: "graduatedStudents",
         | 
| 29 | 
            +
                  label: "Graduated Students",
         | 
| 30 | 
            +
                }
         | 
| 31 | 
            +
            ] %>
         | 
| 32 | 
            +
             | 
| 33 | 
            +
            <% row_styling = [
         | 
| 34 | 
            +
              {
         | 
| 35 | 
            +
                row_id: "1",
         | 
| 36 | 
            +
                cell_padding: "md"
         | 
| 37 | 
            +
              },
         | 
| 38 | 
            +
              {
         | 
| 39 | 
            +
                row_id: "3",
         | 
| 40 | 
            +
                cell_padding: "lg"
         | 
| 41 | 
            +
              },
         | 
| 42 | 
            +
              {
         | 
| 43 | 
            +
                row_id: "5",
         | 
| 44 | 
            +
                cell_padding: "none"
         | 
| 45 | 
            +
              },
         | 
| 46 | 
            +
            ] %>
         | 
| 47 | 
            +
             | 
| 48 | 
            +
            <%= pb_rails("advanced_table", props: { id: "padding-control-per-row", table_data: @table_data_with_id, column_definitions: column_definitions, row_styling: row_styling }) do %>
         | 
| 49 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "padding-control-per-row", column_definitions: column_definitions }) %>
         | 
| 50 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "padding-control-per-row", table_data: @table_data_with_id, column_definitions: column_definitions, row_styling: row_styling }) %>
         | 
| 51 | 
            +
            <% end %>
         | 
    
        data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_padding_control_per_row_rails.md
    ADDED
    
    | @@ -0,0 +1 @@ | |
| 1 | 
            +
            `row_styling` can also be used to control padding on all cells in a given row via the use of the `cell_padding` key/value pair as shown here. `cell_padding` lets you use 'xxs', 'xs', 'sm', 'md', 'lg', 'xl' and 'none'.
         | 
    
        data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_padding_control_rails.html.erb
    ADDED
    
    | @@ -0,0 +1,40 @@ | |
| 1 | 
            +
            <% column_definitions = [
         | 
| 2 | 
            +
                {
         | 
| 3 | 
            +
                  accessor: "year",
         | 
| 4 | 
            +
                  label: "Year",
         | 
| 5 | 
            +
                  cellAccessors: ["quarter", "month", "day"],
         | 
| 6 | 
            +
                },
         | 
| 7 | 
            +
                {
         | 
| 8 | 
            +
                  accessor: "newEnrollments",
         | 
| 9 | 
            +
                  label: "New Enrollments",
         | 
| 10 | 
            +
                  column_styling: { 
         | 
| 11 | 
            +
                    cell_padding: "none",
         | 
| 12 | 
            +
                  }
         | 
| 13 | 
            +
                },
         | 
| 14 | 
            +
                {
         | 
| 15 | 
            +
                  accessor: "scheduledMeetings",
         | 
| 16 | 
            +
                  label: "Scheduled Meetings",
         | 
| 17 | 
            +
                },
         | 
| 18 | 
            +
                {
         | 
| 19 | 
            +
                  accessor: "attendanceRate",
         | 
| 20 | 
            +
                  label: "Attendance Rate",
         | 
| 21 | 
            +
                  column_styling: { cell_padding: "md" },
         | 
| 22 | 
            +
                },
         | 
| 23 | 
            +
                {
         | 
| 24 | 
            +
                  accessor: "completedClasses",
         | 
| 25 | 
            +
                  label: "Completed Classes",
         | 
| 26 | 
            +
                },
         | 
| 27 | 
            +
                {
         | 
| 28 | 
            +
                  accessor: "classCompletionRate",
         | 
| 29 | 
            +
                  label: "Class Completion Rate",
         | 
| 30 | 
            +
                },
         | 
| 31 | 
            +
                {
         | 
| 32 | 
            +
                  accessor: "graduatedStudents",
         | 
| 33 | 
            +
                  label: "Graduated Students",
         | 
| 34 | 
            +
                }
         | 
| 35 | 
            +
            ] %>
         | 
| 36 | 
            +
             | 
| 37 | 
            +
            <%= pb_rails("advanced_table", props: { id: "padding-control", table_data: @table_data, column_definitions: column_definitions }) do %>
         | 
| 38 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "padding-control", column_definitions: column_definitions }) %>
         | 
| 39 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "padding-control", table_data: @table_data, column_definitions: column_definitions }) %>
         | 
| 40 | 
            +
            <% end %>
         | 
| @@ -0,0 +1 @@ | |
| 1 | 
            +
            `column_styling` can also be used to control padding on all cells in a given column via the use of the `cell_padding` key/value pair. `cell_padding` lets you use 'xxs', 'xs', 'sm', 'md', 'lg', 'xl' and 'none'.
         | 
| @@ -1,4 +1,4 @@ | |
| 1 | 
            -
            The `row_styling` prop can be used in conjunction with row ids to control certain styling options on individual rows.  | 
| 1 | 
            +
            The `row_styling` prop can be used in conjunction with row ids to control certain styling options on individual rows. It is an object that has several optional key/value pairs, this doc example highlights the following:
         | 
| 2 2 |  | 
| 3 3 | 
             
            - `background_color` : use this to control the background color of the row
         | 
| 4 4 | 
             
            - `font_color`: use this to control font color for each row if needed, for example if using a darker background color.
         | 
| @@ -1,4 +1,4 @@ | |
| 1 | 
            -
            The `rowStyling` prop can be used in conjunction with row ids to control certain styling options on individual rows.  | 
| 1 | 
            +
            The `rowStyling` prop can be used in conjunction with row ids to control certain styling options on individual rows. It is an object that has several optional key/value pairs, this doc example highlights the following:
         | 
| 2 2 |  | 
| 3 3 | 
             
            - `backgroundColor` : use this to control the background color of the row
         | 
| 4 4 | 
             
            - `fontColor`: use this to control font color for each row if needed, for example if using a darker background color.
         | 
    
        data/app/pb_kits/playbook/pb_advanced_table/docs/_advanced_table_selectable_rows_rails.html.erb
    CHANGED
    
    | @@ -34,6 +34,6 @@ | |
| 34 34 | 
             
            %>
         | 
| 35 35 |  | 
| 36 36 | 
             
            <%= pb_rails("advanced_table", props: { id: "selectable_rows", table_data: @table_data_with_id, column_definitions: column_definitions, selectable_rows: true }) do %>
         | 
| 37 | 
            -
              <%= pb_rails("advanced_table/table_header", props: {  | 
| 38 | 
            -
              <%= pb_rails("advanced_table/table_body", props: {  | 
| 37 | 
            +
              <%= pb_rails("advanced_table/table_header", props: { table_id: "selectable_rows", column_definitions: column_definitions, selectable_rows: true }) %>
         | 
| 38 | 
            +
              <%= pb_rails("advanced_table/table_body", props: { table_id: "selectable_rows", table_data: @table_data_with_id, column_definitions: column_definitions, subrow_headers: subrow_headers, enable_toggle_expansion: "all", selectable_rows: true }) %>
         | 
| 39 39 | 
             
            <% end %>
         | 
| @@ -21,8 +21,11 @@ examples: | |
| 21 21 | 
             
              - advanced_table_selectable_rows_header_rails: Selectable Rows (No Actions Bar)
         | 
| 22 22 | 
             
              - advanced_table_scrollbar_none: Advanced Table Scrollbar None
         | 
| 23 23 | 
             
              - advanced_table_row_styling: Row Styling
         | 
| 24 | 
            +
              - advanced_table_padding_control_per_row_rails: Padding Control using Row Styling
         | 
| 24 25 | 
             
              - advanced_table_column_styling_rails: Column Styling
         | 
| 25 26 | 
             
              - advanced_table_column_styling_column_headers_rails: Column Styling with Multiple Headers
         | 
| 27 | 
            +
              - advanced_table_padding_control_rails: Padding Control using Column Styling
         | 
| 28 | 
            +
              - advanced_table_background_control_rails: Background Control using Column Styling
         | 
| 26 29 | 
             
              - advanced_table_column_border_color_rails: Column Group Border Color
         | 
| 27 30 |  | 
| 28 31 |  | 
| @@ -331,8 +331,12 @@ export default class PbAdvancedTable extends PbEnhancedElement { | |
| 331 331 | 
             
                    // Split the dataContent to get all ancestor IDs, check against ExpandedRows
         | 
| 332 332 | 
             
                    const ancestorIds = dataContent.split("-").slice(0, -1);
         | 
| 333 333 |  | 
| 334 | 
            +
                    // Get the table_id from the child row's parent to construct proper prefixed IDs
         | 
| 335 | 
            +
                    const parentRowId = childRow.dataset.rowParent;
         | 
| 336 | 
            +
                    const tableId = parentRowId ? parentRowId.split('_').slice(0, -1).join('_') : '';
         | 
| 337 | 
            +
             | 
| 334 338 | 
             
                    const prefixedAncestorIds = ancestorIds.map(
         | 
| 335 | 
            -
                      (id) => `${ | 
| 339 | 
            +
                      (id) => `${tableId}_${id}`
         | 
| 336 340 | 
             
                    );
         | 
| 337 341 | 
             
                    const allAncestorsExpanded = prefixedAncestorIds.every((id) =>
         | 
| 338 342 | 
             
                      PbAdvancedTable.expandedRows.has(id)
         | 
| @@ -3,8 +3,8 @@ | |
| 3 3 | 
             
            module Playbook
         | 
| 4 4 | 
             
              module PbAdvancedTable
         | 
| 5 5 | 
             
                class TableBody < Playbook::KitBase
         | 
| 6 | 
            -
                  prop : | 
| 7 | 
            -
             | 
| 6 | 
            +
                  prop :table_id, type: Playbook::Props::String,
         | 
| 7 | 
            +
                                  default: ""
         | 
| 8 8 | 
             
                  prop :table_data, type: Playbook::Props::Array,
         | 
| 9 9 | 
             
                                    default: []
         | 
| 10 10 | 
             
                  prop :column_definitions, type: Playbook::Props::Array,
         | 
| @@ -53,7 +53,7 @@ module Playbook | |
| 53 53 | 
             
                    subrow_data_attributes = {
         | 
| 54 54 | 
             
                      advanced_table_content: subrow_ancestor_ids.join("-"),
         | 
| 55 55 | 
             
                      row_depth: current_depth,
         | 
| 56 | 
            -
                      row_parent: "#{ | 
| 56 | 
            +
                      row_parent: "#{table_id}_#{ancestor_ids.last}",
         | 
| 57 57 | 
             
                    }
         | 
| 58 58 | 
             
                    # Subrow header if applicable
         | 
| 59 59 | 
             
                    output << pb_rails("advanced_table/table_subrow_header", props: { row: row, column_definitions: leaf_columns, depth: current_depth, subrow_header: subrow_headers[current_depth - 1], collapsible_trail: collapsible_trail, classname: "toggle-content", responsive: responsive, subrow_data_attributes: subrow_data_attributes, last_row: last_row, immediate_parent_row_id: immediate_parent_row_id }) if is_first_child_of_subrow && enable_toggle_expansion == "all"
         | 
| @@ -69,7 +69,7 @@ module Playbook | |
| 69 69 | 
             
                                              end
         | 
| 70 70 |  | 
| 71 71 | 
             
                    # Additional class and data attributes needed for toggle logic
         | 
| 72 | 
            -
                    output << pb_rails("advanced_table/table_row", props: {  | 
| 72 | 
            +
                    output << pb_rails("advanced_table/table_row", props: { table_id: table_id, row: row, column_definitions: leaf_columns, depth: current_depth, collapsible_trail: collapsible_trail, classname: additional_classes, table_data_attributes: current_data_attributes, responsive: responsive, loading: loading, selectable_rows: selectable_rows, row_id: row[:id], enable_toggle_expansion: enable_toggle_expansion, row_styling: row_styling, last_row: last_row, immediate_parent_row_id: immediate_parent_row_id })
         | 
| 73 73 |  | 
| 74 74 | 
             
                    if row[:children].present?
         | 
| 75 75 | 
             
                      row[:children].each do |child_row|
         | 
| @@ -78,9 +78,9 @@ module Playbook | |
| 78 78 | 
             
                        data_content = new_ancestor_ids.join("-") + "-#{child_row.object_id}"
         | 
| 79 79 |  | 
| 80 80 | 
             
                        child_data_attributes = {
         | 
| 81 | 
            -
                          top_parent: "#{ | 
| 81 | 
            +
                          top_parent: "#{table_id}_#{top_parent_id}",
         | 
| 82 82 | 
             
                          row_depth: current_depth + 1,
         | 
| 83 | 
            -
                          row_parent: "#{ | 
| 83 | 
            +
                          row_parent: "#{table_id}_#{immediate_parent_id}",
         | 
| 84 84 | 
             
                          advanced_table_content: data_content,
         | 
| 85 85 | 
             
                        }
         | 
| 86 86 |  | 
| @@ -3,8 +3,8 @@ | |
| 3 3 | 
             
            module Playbook
         | 
| 4 4 | 
             
              module PbAdvancedTable
         | 
| 5 5 | 
             
                class TableHeader < Playbook::KitBase
         | 
| 6 | 
            -
                  prop : | 
| 7 | 
            -
             | 
| 6 | 
            +
                  prop :table_id, type: Playbook::Props::String,
         | 
| 7 | 
            +
                                  default: ""
         | 
| 8 8 | 
             
                  prop :column_definitions, type: Playbook::Props::Array,
         | 
| 9 9 | 
             
                                            default: []
         | 
| 10 10 | 
             
                  prop :enable_toggle_expansion, type: Playbook::Props::Enum,
         | 
| @@ -58,10 +58,10 @@ module Playbook | |
| 58 58 | 
             
                                 classname: additional_classes.join(" "),
         | 
| 59 59 | 
             
                               }) do
         | 
| 60 60 | 
             
                        pb_rails("checkbox", props: {
         | 
| 61 | 
            -
                                   id: "#{ | 
| 61 | 
            +
                                   id: "#{table_id ? "#{table_id}-" : ''}select-all-rows",
         | 
| 62 62 | 
             
                                   indeterminate_main: true,
         | 
| 63 63 | 
             
                                   indeterminate_main_labels: ["", ""],
         | 
| 64 | 
            -
                                   name: "#{ | 
| 64 | 
            +
                                   name: "#{table_id ? "#{table_id}-" : ''}select-all-rows",
         | 
| 65 65 | 
             
                                 })
         | 
| 66 66 | 
             
                      end
         | 
| 67 67 | 
             
                    end
         | 
| @@ -71,10 +71,10 @@ module Playbook | |
| 71 71 | 
             
                  def render_select_all_checkbox
         | 
| 72 72 | 
             
                    if selectable_rows
         | 
| 73 73 | 
             
                      pb_rails("checkbox", props: {
         | 
| 74 | 
            -
                                 id: "#{ | 
| 74 | 
            +
                                 id: "#{table_id ? "#{table_id}-" : ''}select-all-rows",
         | 
| 75 75 | 
             
                                 indeterminate_main: true,
         | 
| 76 76 | 
             
                                 indeterminate_main_labels: ["", ""],
         | 
| 77 | 
            -
                                 name: "#{ | 
| 77 | 
            +
                                 name: "#{table_id ? "#{table_id}-" : ''}select-all-rows",
         | 
| 78 78 | 
             
                                 data: {
         | 
| 79 79 | 
             
                                   action: "click->pb-advanced-table#toggleAllRowSelection",
         | 
| 80 80 | 
             
                                 },
         | 
| @@ -12,7 +12,8 @@ | |
| 12 12 | 
             
                <% end %>
         | 
| 13 13 | 
             
                <% object.column_definitions.each_with_index do |column, index| %>
         | 
| 14 14 | 
             
                    <% next unless column[:accessor].present? %>
         | 
| 15 | 
            -
                     | 
| 15 | 
            +
                    <% component_info = object.cell_component_info(column, index, bg_color, font_color) %>
         | 
| 16 | 
            +
                    <%= pb_rails(component_info[:name], props: component_info[:props]) do %>
         | 
| 16 17 | 
             
                        <%= pb_rails("flex", props:{ align: "center", justify: object.justify_for(column, index), classname: object.loading ? "loading-cell" : "" }) do %>
         | 
| 17 18 | 
             
                            <% if collapsible_trail && index.zero? %>
         | 
| 18 19 | 
             
                                <% (1..depth).each do |i| %>
         | 
| @@ -33,7 +34,7 @@ | |
| 33 34 | 
             
                                        <% end %>
         | 
| 34 35 | 
             
                                        <% if object.row[:children].present? %>
         | 
| 35 36 | 
             
                                            <button
         | 
| 36 | 
            -
                                                id="<%= "#{object. | 
| 37 | 
            +
                                                id="<%= "#{object.table_id}_#{object.row.object_id}" %>"
         | 
| 37 38 | 
             
                                                class="gray-icon expand-toggle-icon"
         | 
| 38 39 | 
             
                                                data-advanced-table="true"
         | 
| 39 40 | 
             
                                                style="color: <%= button_color %>"
         | 
| @@ -3,8 +3,8 @@ | |
| 3 3 | 
             
            module Playbook
         | 
| 4 4 | 
             
              module PbAdvancedTable
         | 
| 5 5 | 
             
                class TableRow < Playbook::KitBase
         | 
| 6 | 
            -
                  prop : | 
| 7 | 
            -
             | 
| 6 | 
            +
                  prop :table_id, type: Playbook::Props::String,
         | 
| 7 | 
            +
                                  default: ""
         | 
| 8 8 | 
             
                  prop :column_definitions, type: Playbook::Props::Array,
         | 
| 9 9 | 
             
                                            default: []
         | 
| 10 10 | 
             
                  prop :row
         | 
| @@ -46,9 +46,53 @@ module Playbook | |
| 46 46 | 
             
                    classes = %w[id-cell]
         | 
| 47 47 | 
             
                    classes << "last-cell" if column[:is_last_in_group]
         | 
| 48 48 | 
             
                    classes << "pinned-left" if index.zero? && is_pinned_left && responsive == "scroll"
         | 
| 49 | 
            +
             | 
| 50 | 
            +
                    row_style = row_styling.find { |style| style[:row_id].to_s == row_id.to_s }
         | 
| 51 | 
            +
                    row_padding = row_style&.[](:cell_padding)
         | 
| 52 | 
            +
             | 
| 53 | 
            +
                    if column[:accessor].present?
         | 
| 54 | 
            +
                      orig_def = find_column_def_by_accessor(column_definitions, column[:accessor])
         | 
| 55 | 
            +
                      column_padding = orig_def[:column_styling][:cell_padding] if orig_def && orig_def[:column_styling].is_a?(Hash) && orig_def[:column_styling][:cell_padding].present?
         | 
| 56 | 
            +
                    end
         | 
| 57 | 
            +
             | 
| 58 | 
            +
                    classes << "p_#{row_padding}" if row_padding.present?
         | 
| 59 | 
            +
                    classes << "p_#{column_padding}" if column_padding.present?
         | 
| 60 | 
            +
             | 
| 49 61 | 
             
                    classes.join(" ")
         | 
| 50 62 | 
             
                  end
         | 
| 51 63 |  | 
| 64 | 
            +
                  def cell_background_color(column)
         | 
| 65 | 
            +
                    return nil unless column[:accessor].present?
         | 
| 66 | 
            +
             | 
| 67 | 
            +
                    orig_def = find_column_def_by_accessor(column_definitions, column[:accessor])
         | 
| 68 | 
            +
                    if orig_def && orig_def[:column_styling].is_a?(Hash) && orig_def[:column_styling][:cell_background_color].present?
         | 
| 69 | 
            +
                      bg_color = orig_def[:column_styling][:cell_background_color]
         | 
| 70 | 
            +
                      if bg_color.respond_to?(:call)
         | 
| 71 | 
            +
                        bg_color.call(row)
         | 
| 72 | 
            +
                      else
         | 
| 73 | 
            +
                        bg_color
         | 
| 74 | 
            +
                      end
         | 
| 75 | 
            +
                    end
         | 
| 76 | 
            +
                  end
         | 
| 77 | 
            +
             | 
| 78 | 
            +
                  def has_custom_background_color?(column)
         | 
| 79 | 
            +
                    cell_background_color(column).present?
         | 
| 80 | 
            +
                  end
         | 
| 81 | 
            +
             | 
| 82 | 
            +
                  # Uses a regular table/table_cell component if there is no custom background color; if there is a cell_background_color uses a background component with tag "td"
         | 
| 83 | 
            +
                  def cell_component_info(column, index, bg_color, font_color)
         | 
| 84 | 
            +
                    if has_custom_background_color?(column)
         | 
| 85 | 
            +
                      custom_bg_color = cell_background_color(column)
         | 
| 86 | 
            +
                      component_name = "background"
         | 
| 87 | 
            +
                      component_props = { background_color: custom_bg_color, tag: "td", classname: td_classname(column, index) }
         | 
| 88 | 
            +
                    else
         | 
| 89 | 
            +
                      component_name = "table/table_cell"
         | 
| 90 | 
            +
                      component_props = { html_options: { style: { "background-color": bg_color, color: font_color } }, classname: td_classname(column, index) }
         | 
| 91 | 
            +
                    end
         | 
| 92 | 
            +
             | 
| 93 | 
            +
                    { name: component_name, props: component_props }
         | 
| 94 | 
            +
                  end
         | 
| 95 | 
            +
             | 
| 52 96 | 
             
                  def depth_accessors
         | 
| 53 97 | 
             
                    column_definitions.flat_map do |column|
         | 
| 54 98 | 
             
                      column[:cellAccessors] if column.key?(:cellAccessors)
         | 
| @@ -58,13 +102,13 @@ module Playbook | |
| 58 102 | 
             
                  # Selectable Rows No Subrows - checkboxes in their own first cell
         | 
| 59 103 | 
             
                  def render_checkbox_cell
         | 
| 60 104 | 
             
                    if selectable_rows
         | 
| 61 | 
            -
                      prefix =  | 
| 105 | 
            +
                      prefix = table_id ? "#{table_id}-" : ""
         | 
| 62 106 | 
             
                      pb_rails("table/table_cell", props: {
         | 
| 63 107 | 
             
                                 classname: "checkbox-cell",
         | 
| 64 108 | 
             
                               }) do
         | 
| 65 109 | 
             
                        pb_rails("checkbox", props: {
         | 
| 66 110 | 
             
                                   id: "#{prefix}select-row-#{row_id || row.object_id}",
         | 
| 67 | 
            -
                                   indeterminate_parent: "#{ | 
| 111 | 
            +
                                   indeterminate_parent: "#{table_id ? "#{table_id}-" : ''}select-all-rows",
         | 
| 68 112 | 
             
                                   name: "#{prefix}select-row-#{row_id || row.object_id}",
         | 
| 69 113 | 
             
                                   data: {
         | 
| 70 114 | 
             
                                     row_id: row_id || row.object_id.to_s,
         | 
| @@ -78,7 +122,7 @@ module Playbook | |
| 78 122 | 
             
                  # Selectable Rows w/ Subrows - checkboxes part of toggleable first cell
         | 
| 79 123 | 
             
                  def render_row_checkbox
         | 
| 80 124 | 
             
                    if selectable_rows
         | 
| 81 | 
            -
                      prefix =  | 
| 125 | 
            +
                      prefix = table_id ? "#{table_id}-" : ""
         | 
| 82 126 | 
             
                      indeterminate_parent =
         | 
| 83 127 | 
             
                        if depth.zero?
         | 
| 84 128 | 
             
                          "#{prefix}select-all-rows"
         | 
| @@ -1,13 +1,13 @@ | |
| 1 1 |  | 
| 2 2 | 
             
            <div>
         | 
| 3 3 | 
             
              <%= pb_rails("bread_crumbs", props: { aria: { label: "Breadcrumb Navigation" } }) do%>
         | 
| 4 | 
            -
                <%= pb_rails("icon", props: { icon: "home"}) %>
         | 
| 4 | 
            +
                <%= pb_rails("icon", props: { icon: "home", color: "link"}) %>
         | 
| 5 5 | 
             
                <%= pb_rails("bread_crumbs/bread_crumb_item", props: { link: "/" }) do %> 
         | 
| 6 | 
            -
                  <%= pb_rails("title", props: { size: 4, text: "Home", tag: "span" }) %>
         | 
| 6 | 
            +
                  <%= pb_rails("title", props: { size: 4, text: "Home", tag: "span", color: "link" }) %>
         | 
| 7 7 | 
             
                 <%end%>
         | 
| 8 | 
            -
                 <%= pb_rails("icon", props: { icon: 'users'}) %>
         | 
| 8 | 
            +
                 <%= pb_rails("icon", props: { icon: 'users', color: "link"}) %>
         | 
| 9 9 | 
             
                <%= pb_rails("bread_crumbs/bread_crumb_item", props: { link: "/users" }) do %> 
         | 
| 10 | 
            -
                  <%= pb_rails("title", props: { size: 4, text: "Users", tag: "span" }) %>
         | 
| 10 | 
            +
                  <%= pb_rails("title", props: { size: 4, text: "Users", tag: "span", color: "link" }) %>
         | 
| 11 11 | 
             
                 <%end%>
         | 
| 12 12 | 
             
                 <%= pb_rails("icon", props: { icon: "user"}) %>
         | 
| 13 13 | 
             
                <%= pb_rails("bread_crumbs/bread_crumb_item") do %> 
         | 
| @@ -12,6 +12,7 @@ const BreadCrumbsDefault = (props) => { | |
| 12 12 | 
             
                    {...props}
         | 
| 13 13 | 
             
                >
         | 
| 14 14 | 
             
                  <Icon
         | 
| 15 | 
            +
                      color="link"
         | 
| 15 16 | 
             
                      icon="home"
         | 
| 16 17 | 
             
                      size="1x"
         | 
| 17 18 | 
             
                      {...props}
         | 
| @@ -21,6 +22,7 @@ const BreadCrumbsDefault = (props) => { | |
| 21 22 | 
             
                      href="/home"
         | 
| 22 23 | 
             
                  >
         | 
| 23 24 | 
             
                    <Title
         | 
| 25 | 
            +
                        color="link"
         | 
| 24 26 | 
             
                        size="4"
         | 
| 25 27 | 
             
                        tag="span"
         | 
| 26 28 | 
             
                        text="Home"
         | 
| @@ -28,6 +30,7 @@ const BreadCrumbsDefault = (props) => { | |
| 28 30 | 
             
                    />
         | 
| 29 31 | 
             
                  </BreadCrumbItem>
         | 
| 30 32 | 
             
                  <Icon
         | 
| 33 | 
            +
                      color="link"
         | 
| 31 34 | 
             
                      icon="users"
         | 
| 32 35 | 
             
                      size="1x"
         | 
| 33 36 | 
             
                      {...props}
         | 
| @@ -37,6 +40,7 @@ const BreadCrumbsDefault = (props) => { | |
| 37 40 | 
             
                      href="/users"
         | 
| 38 41 | 
             
                  >
         | 
| 39 42 | 
             
                    <Title
         | 
| 43 | 
            +
                        color="link"
         | 
| 40 44 | 
             
                        size="4"
         | 
| 41 45 | 
             
                        tag="span"
         | 
| 42 46 | 
             
                        text="Users"
         | 
| @@ -1,3 +1,7 @@ | |
| 1 | 
            -
            <%= pb_rails(" | 
| 2 | 
            -
            <%= pb_rails("button", props: { aria: { label: "Loading" },  | 
| 3 | 
            -
            <%= pb_rails("button", props: { aria: { label: "Loading" },  | 
| 1 | 
            +
            <%= pb_rails("caption", props: { margin_y: "md", text: "Button variants with loading" }) %>
         | 
| 2 | 
            +
            <%= pb_rails("button", props: { aria: { label: "Loading" }, loading: true, margin_right: "lg" }) %>
         | 
| 3 | 
            +
            <%= pb_rails("button", props: { aria: { label: "Loading" }, variant: "secondary", loading: true, margin_right: "lg" }) %>
         | 
| 4 | 
            +
            <%= pb_rails("button", props: { aria: { label: "Loading" }, variant: "link", loading: true, margin_right: "lg" }) %>
         | 
| 5 | 
            +
            <%= pb_rails("caption", props: { margin_y: "md", text: "Button sizes with loading" }) %>
         | 
| 6 | 
            +
            <%= pb_rails("button", props: { aria: { label: "Loading" }, loading: true, size: "sm", margin_right: "lg" }) %>
         | 
| 7 | 
            +
            <%= pb_rails("button", props: { aria: { label: "Loading" }, loading: true, size: "lg", margin_right: "lg" }) %>
         |