playbook_ui 2.7.2 → 2.8.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/app/controllers/playbook/application_controller.rb +2 -0
- data/app/controllers/playbook/guides_controller.rb +3 -0
- data/app/controllers/playbook/pages_controller.rb +21 -21
- data/app/helpers/playbook/application_helper.rb +2 -0
- data/app/helpers/playbook/layout_helper.rb +7 -5
- data/app/helpers/playbook/pb_doc_helper.rb +17 -15
- data/app/helpers/playbook/pb_kit_helper.rb +11 -9
- data/app/helpers/playbook/redcarpet_helper.rb +41 -44
- data/app/pb_kits/playbook/packs/application.js +6 -4
- data/app/pb_kits/playbook/packs/examples.js +62 -2
- data/app/pb_kits/playbook/packs/index.js +57 -0
- data/app/pb_kits/playbook/packs/kits.js +18 -0
- data/app/pb_kits/playbook/packs/pb_bar_graph.js +4 -0
- data/app/pb_kits/playbook/packs/pb_dashboard_value.js +4 -0
- data/app/pb_kits/playbook/packs/pb_date.js +4 -0
- data/app/pb_kits/playbook/packs/pb_icon.js +4 -0
- data/app/pb_kits/playbook/packs/pb_icon_circle.js +4 -0
- data/app/pb_kits/playbook/packs/pb_icon_value.js +4 -0
- data/app/pb_kits/playbook/packs/pb_label_value.js +4 -0
- data/app/pb_kits/playbook/packs/pb_line_graph.js +4 -0
- data/app/pb_kits/playbook/packs/pb_message.js +4 -0
- data/app/pb_kits/playbook/packs/pb_online_status.js +4 -0
- data/app/pb_kits/playbook/packs/pb_pill.js +4 -0
- data/app/pb_kits/playbook/packs/pb_progress_simple.js +4 -0
- data/app/pb_kits/playbook/packs/pb_star_rating.js +4 -0
- data/app/pb_kits/playbook/packs/pb_time.js +4 -0
- data/app/pb_kits/playbook/packs/pb_timestamp.js +4 -0
- data/app/pb_kits/playbook/packs/pb_title_count.js +4 -0
- data/app/pb_kits/playbook/packs/pb_title_detail.js +4 -0
- data/app/pb_kits/playbook/packs/pb_user.js +4 -0
- data/app/pb_kits/playbook/packs/pb_user_badge.js +4 -0
- data/app/pb_kits/playbook/packs/site_styles/_kit_style_index.scss +19 -1
- data/app/pb_kits/playbook/packs/site_styles/_scaffold.scss +1 -1
- data/app/pb_kits/playbook/packs/site_styles/_site-style.scss +4 -4
- data/app/pb_kits/playbook/packs/site_styles/docs/_kit_doc.scss +16 -3
- data/app/pb_kits/playbook/packs/site_styles/docs/_markdown.scss +7 -7
- data/app/pb_kits/playbook/packs/site_styles/docs/_spacing_tokens.scss +2 -2
- data/app/pb_kits/playbook/pb_avatar/_avatar.html.erb +7 -3
- data/app/pb_kits/playbook/pb_avatar/_avatar.jsx +1 -1
- data/app/pb_kits/playbook/pb_avatar/_avatar.scss +73 -30
- data/app/pb_kits/playbook/pb_avatar/avatar.rb +39 -42
- data/app/pb_kits/playbook/pb_avatar/docs/_avatar_default.html.erb +42 -5
- data/app/pb_kits/playbook/pb_avatar/docs/_avatar_status.html.erb +32 -0
- data/app/pb_kits/playbook/pb_avatar/docs/example.yml +1 -0
- data/app/pb_kits/playbook/pb_bar_graph/_bar_graph.html.erb +19 -0
- data/app/pb_kits/playbook/pb_bar_graph/_bar_graph.jsx +21 -0
- data/app/pb_kits/playbook/pb_bar_graph/_bar_graph.scss +3 -0
- data/app/pb_kits/playbook/pb_bar_graph/barGraphSettings.js +24 -0
- data/app/pb_kits/playbook/pb_bar_graph/bar_graph.rb +86 -0
- data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_default.html.erb +20 -0
- data/app/pb_kits/playbook/pb_bar_graph/docs/_bar_graph_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_bar_graph/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_bar_graph/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_body/_body.html.erb +6 -4
- data/app/pb_kits/playbook/pb_body/_body.scss +11 -31
- data/app/pb_kits/playbook/pb_body/_body_mixins.scss +53 -0
- data/app/pb_kits/playbook/pb_body/body.rb +61 -38
- data/app/pb_kits/playbook/pb_body/docs/_body_dark.html.erb +19 -3
- data/app/pb_kits/playbook/pb_body/docs/_body_light.html.erb +21 -3
- data/app/pb_kits/playbook/pb_button/_button.html.erb +19 -8
- data/app/pb_kits/playbook/pb_button/_button.scss +23 -47
- data/app/pb_kits/playbook/pb_button/_button_mixins.scss +116 -0
- data/app/pb_kits/playbook/pb_button/button.rb +95 -51
- data/app/pb_kits/playbook/pb_button/docs/_button_accessibility.html.erb +1 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_block_content.html.erb +4 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_default.html.erb +4 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_default_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_full_width.html.erb +1 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_link.html.erb +3 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_loading.html.erb +3 -0
- data/app/pb_kits/playbook/pb_button/docs/example.yml +7 -3
- data/app/pb_kits/playbook/pb_caption/_caption.html.erb +5 -2
- data/app/pb_kits/playbook/pb_caption/_caption.scss +9 -1
- data/app/pb_kits/playbook/pb_caption/_caption_mixin.scss +10 -13
- data/app/pb_kits/playbook/pb_caption/caption.rb +35 -40
- data/app/pb_kits/playbook/pb_card/_card.html.erb +3 -2
- data/app/pb_kits/playbook/pb_card/_card.scss +20 -1
- data/app/pb_kits/playbook/pb_card/card.rb +34 -9
- data/app/pb_kits/playbook/pb_card/docs/_card_light.html.erb +1 -1
- data/app/pb_kits/playbook/pb_dashboard/commonSettings.js +84 -0
- data/app/pb_kits/playbook/pb_dashboard/pbChartPlugin.js +120 -0
- data/app/pb_kits/playbook/pb_dashboard/pbChartsLightTheme.js +162 -0
- data/app/pb_kits/playbook/pb_dashboard_value/_dashboard_value.html.erb +8 -0
- data/app/pb_kits/playbook/pb_dashboard_value/_dashboard_value.jsx +21 -0
- data/app/pb_kits/playbook/pb_dashboard_value/_dashboard_value.scss +10 -0
- data/app/pb_kits/playbook/pb_dashboard_value/_dashboard_value_mixins.scss +12 -0
- data/app/pb_kits/playbook/pb_dashboard_value/child_kits/_stat_change.html.erb +6 -0
- data/app/pb_kits/playbook/pb_dashboard_value/child_kits/_stat_label.html.erb +6 -0
- data/app/pb_kits/playbook/pb_dashboard_value/child_kits/_stat_value.html.erb +10 -0
- data/app/pb_kits/playbook/pb_dashboard_value/child_kits/_stat_value.scss +7 -0
- data/app/pb_kits/playbook/pb_dashboard_value/dashboardValueSettings.js +47 -0
- data/app/pb_kits/playbook/pb_dashboard_value/dashboard_value.rb +79 -0
- data/app/pb_kits/playbook/pb_dashboard_value/docs/_dashboard_value_align.html.erb +23 -0
- data/app/pb_kits/playbook/pb_dashboard_value/docs/_dashboard_value_change.html.erb +15 -0
- data/app/pb_kits/playbook/pb_dashboard_value/docs/_dashboard_value_default.html.erb +21 -0
- data/app/pb_kits/playbook/pb_dashboard_value/docs/_dashboard_value_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_dashboard_value/docs/_dashboard_value_label.html.erb +19 -0
- data/app/pb_kits/playbook/pb_dashboard_value/docs/example.yml +11 -0
- data/app/pb_kits/playbook/pb_dashboard_value/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_dashboard_value/stat_change.rb +93 -0
- data/app/pb_kits/playbook/pb_dashboard_value/stat_label.rb +53 -0
- data/app/pb_kits/playbook/pb_dashboard_value/stat_value.rb +63 -0
- data/app/pb_kits/playbook/pb_date/_date.html.erb +6 -0
- data/app/pb_kits/playbook/pb_date/_date.jsx +21 -0
- data/app/pb_kits/playbook/pb_date/_date.scss +5 -0
- data/app/pb_kits/playbook/pb_date/date.rb +105 -0
- data/app/pb_kits/playbook/pb_date/docs/_date_default.html.erb +10 -0
- data/app/pb_kits/playbook/pb_date/docs/_date_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_date/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_date/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_icon/_icon.html.erb +7 -0
- data/app/pb_kits/playbook/pb_icon/_icon.jsx +21 -0
- data/app/pb_kits/playbook/pb_icon/_icon.scss +3 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_animate.html.erb +3 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_border.html.erb +1 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_default.html.erb +1 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_default_dark.html.erb +1 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_flip.html.erb +3 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_pull.html.erb +2 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_rotate.html.erb +3 -0
- data/app/pb_kits/playbook/pb_icon/docs/_icon_sizes.html.erb +16 -0
- data/app/pb_kits/playbook/pb_icon/docs/example.yml +12 -0
- data/app/pb_kits/playbook/pb_icon/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_icon/icon.rb +160 -0
- data/app/pb_kits/playbook/pb_icon_circle/_icon_circle.html.erb +6 -0
- data/app/pb_kits/playbook/pb_icon_circle/_icon_circle.jsx +21 -0
- data/app/pb_kits/playbook/pb_icon_circle/_icon_circle.scss +57 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_color.html.erb +35 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_default.html.erb +3 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/_icon_circle_sizes.html.erb +24 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/example.yml +10 -0
- data/app/pb_kits/playbook/pb_icon_circle/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_icon_circle/icon_circle.rb +67 -0
- data/app/pb_kits/playbook/pb_icon_value/_icon_value.html.erb +6 -0
- data/app/pb_kits/playbook/pb_icon_value/_icon_value.jsx +21 -0
- data/app/pb_kits/playbook/pb_icon_value/_icon_value.scss +30 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/_icon_value_align.html.erb +20 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/_icon_value_default.html.erb +18 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/_icon_value_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_icon_value/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_icon_value/icon_value.rb +78 -0
- data/app/pb_kits/playbook/pb_image/_image.html.erb +2 -1
- data/app/pb_kits/playbook/pb_image/image.rb +26 -20
- data/app/pb_kits/playbook/pb_input/input.rb +21 -16
- data/app/pb_kits/playbook/pb_kit/base.rb +74 -13
- data/app/pb_kits/playbook/pb_label_value/_label_value.html.erb +7 -0
- data/app/pb_kits/playbook/pb_label_value/_label_value.jsx +21 -0
- data/app/pb_kits/playbook/pb_label_value/_label_value.scss +7 -0
- data/app/pb_kits/playbook/pb_label_value/docs/_label_value_default.html.erb +21 -0
- data/app/pb_kits/playbook/pb_label_value/docs/_label_value_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_label_value/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_label_value/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_label_value/label_value.rb +56 -0
- data/app/pb_kits/playbook/pb_layout/_layout.scss +2 -2
- data/app/pb_kits/playbook/pb_layout/_layout_mixin.scss +6 -6
- data/app/pb_kits/playbook/pb_layout/body.rb +9 -7
- data/app/pb_kits/playbook/pb_layout/layout.rb +26 -42
- data/app/pb_kits/playbook/pb_layout/sidebar.rb +9 -7
- data/app/pb_kits/playbook/pb_line_graph/_line_graph.html.erb +19 -0
- data/{lib/generators/kit/templates/jsx.erb → app/pb_kits/playbook/pb_line_graph/_line_graph.jsx} +4 -4
- data/{components/SearchCollectionSelect/searchCollectionSelect.scss → app/pb_kits/playbook/pb_line_graph/_line_graph.scss} +0 -0
- data/app/pb_kits/playbook/pb_line_graph/docs/_rails.html.erb +21 -0
- data/app/pb_kits/playbook/pb_line_graph/docs/_react.html.erb +2 -0
- data/app/pb_kits/playbook/pb_line_graph/docs/example.yml +5 -0
- data/app/pb_kits/playbook/pb_line_graph/lineGraphSettings.js +15 -0
- data/app/pb_kits/playbook/pb_line_graph/line_graph.rb +85 -0
- data/app/pb_kits/playbook/pb_list/_item.html.erb +1 -1
- data/app/pb_kits/playbook/pb_list/_list.scss +15 -78
- data/app/pb_kits/playbook/pb_list/_list_mixin.scss +91 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_borderless.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_dark.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_borderless.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_lg.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_ordered.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_xpadding.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_default.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_lg.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_ordered.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/docs/_list_xpadding.html.erb +6 -6
- data/app/pb_kits/playbook/pb_list/item.rb +14 -16
- data/app/pb_kits/playbook/pb_list/list.rb +30 -29
- data/app/pb_kits/playbook/pb_message/_message.html.erb +11 -0
- data/app/pb_kits/playbook/pb_message/_message.jsx +21 -0
- data/app/pb_kits/playbook/pb_message/_message.scss +5 -0
- data/app/pb_kits/playbook/pb_message/_message_mixins.scss +24 -0
- data/app/pb_kits/playbook/pb_message/docs/_message_default.html.erb +63 -0
- data/app/pb_kits/playbook/pb_message/docs/_message_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_message/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_message/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_message/message.rb +89 -0
- data/app/pb_kits/playbook/pb_online_status/_online_status.html.erb +5 -0
- data/app/pb_kits/playbook/pb_online_status/_online_status.jsx +21 -0
- data/app/pb_kits/playbook/pb_online_status/_online_status.scss +20 -0
- data/app/pb_kits/playbook/pb_online_status/_online_status_mixins.scss +35 -0
- data/app/pb_kits/playbook/pb_online_status/docs/_online_status_default.html.erb +9 -0
- data/app/pb_kits/playbook/pb_online_status/docs/_online_status_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_online_status/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_online_status/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_online_status/online_status.rb +48 -0
- data/app/pb_kits/playbook/pb_pill/_pill.html.erb +6 -0
- data/app/pb_kits/playbook/pb_pill/_pill.jsx +21 -0
- data/app/pb_kits/playbook/pb_pill/_pill.scss +24 -0
- data/app/pb_kits/playbook/pb_pill/docs/_pill_default.html.erb +38 -0
- data/app/pb_kits/playbook/pb_pill/docs/_pill_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_pill/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_pill/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_pill/pill.rb +62 -0
- data/app/pb_kits/playbook/pb_progress_simple/_progress_simple.html.erb +11 -0
- data/app/pb_kits/playbook/pb_progress_simple/_progress_simple.jsx +21 -0
- data/app/pb_kits/playbook/pb_progress_simple/_progress_simple.scss +45 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/_progress_simple_align.html.erb +5 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/_progress_simple_default.html.erb +1 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/_progress_simple_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/_progress_simple_muted.html.erb +1 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/_progress_simple_value.html.erb +5 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/_progress_simple_width.html.erb +1 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/example.yml +12 -0
- data/app/pb_kits/playbook/pb_progress_simple/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_progress_simple/progress_simple.rb +100 -0
- data/app/pb_kits/playbook/pb_star_rating/_star_rating.html.erb +28 -0
- data/app/pb_kits/playbook/pb_star_rating/_star_rating.jsx +21 -0
- data/app/pb_kits/playbook/pb_star_rating/_star_rating.scss +60 -0
- data/app/pb_kits/playbook/pb_star_rating/docs/_star_rating_default.html.erb +13 -0
- data/app/pb_kits/playbook/pb_star_rating/docs/_star_rating_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_star_rating/docs/_star_rating_hide.html.erb +1 -0
- data/app/pb_kits/playbook/pb_star_rating/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_star_rating/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_star_rating/star_rating.rb +70 -0
- data/app/pb_kits/playbook/pb_table/_table.html.erb +1 -5
- data/app/pb_kits/playbook/pb_table/styles/_as-cards.scss +1 -1
- data/app/pb_kits/playbook/pb_table/styles/_content.scss +1 -1
- data/app/pb_kits/playbook/pb_table/styles/_headers.scss +3 -3
- data/app/pb_kits/playbook/pb_table/styles/_hover.scss +7 -5
- data/app/pb_kits/playbook/pb_table/styles/_mobile.scss +103 -100
- data/app/pb_kits/playbook/pb_table/styles/_reset.scss +1 -1
- data/app/pb_kits/playbook/pb_table/styles/_single-line.scss +1 -1
- data/app/pb_kits/playbook/pb_table/styles/_structure.scss +5 -3
- data/app/pb_kits/playbook/pb_table/styles/_table-card.scss +5 -5
- data/app/pb_kits/playbook/pb_table/styles/_table-dark.scss +64 -58
- data/app/pb_kits/playbook/pb_table/styles/_variables.scss +3 -0
- data/app/pb_kits/playbook/pb_table/table.rb +50 -50
- data/app/pb_kits/playbook/pb_time/_time.html.erb +6 -0
- data/app/pb_kits/playbook/pb_time/_time.jsx +21 -0
- data/app/pb_kits/playbook/pb_time/_time.scss +25 -0
- data/app/pb_kits/playbook/pb_time/docs/_time_default.html.erb +23 -0
- data/app/pb_kits/playbook/pb_time/docs/_time_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_time/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_time/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_time/time.rb +135 -0
- data/app/pb_kits/playbook/pb_timestamp/_timestamp-mixins.scss +10 -0
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.html.erb +6 -0
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.jsx +21 -0
- data/app/pb_kits/playbook/pb_timestamp/_timestamp.scss +5 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_default.html.erb +1 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/_timestamp_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_timestamp/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_timestamp/timestamp.rb +50 -0
- data/app/pb_kits/playbook/pb_title/_title.html.erb +4 -1
- data/app/pb_kits/playbook/pb_title/_title.scss +12 -21
- data/app/pb_kits/playbook/pb_title/_title_mixin.scss +18 -40
- data/app/pb_kits/playbook/pb_title/docs/_title_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_title/docs/_title_light.html.erb +4 -0
- data/app/pb_kits/playbook/pb_title/title.rb +39 -37
- data/app/pb_kits/playbook/pb_title_count/_title_count.html.erb +7 -0
- data/app/pb_kits/playbook/pb_title_count/_title_count.jsx +21 -0
- data/app/pb_kits/playbook/pb_title_count/_title_count.scss +17 -0
- data/app/pb_kits/playbook/pb_title_count/docs/_title_count_align.html.erb +20 -0
- data/app/pb_kits/playbook/pb_title_count/docs/_title_count_default.html.erb +20 -0
- data/app/pb_kits/playbook/pb_title_count/docs/_title_count_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_title_count/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_title_count/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_title_count/title_count.rb +88 -0
- data/app/pb_kits/playbook/pb_title_detail/_title_detail.html.erb +7 -0
- data/app/pb_kits/playbook/pb_title_detail/_title_detail.jsx +21 -0
- data/app/pb_kits/playbook/pb_title_detail/_title_detail.scss +14 -0
- data/app/pb_kits/playbook/pb_title_detail/docs/_title_detail_default.html.erb +16 -0
- data/app/pb_kits/playbook/pb_title_detail/docs/_title_detail_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_title_detail/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_title_detail/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_title_detail/title_detail.rb +70 -0
- data/app/pb_kits/playbook/pb_user/_user.html.erb +11 -0
- data/app/pb_kits/playbook/pb_user/_user.jsx +21 -0
- data/app/pb_kits/playbook/pb_user/_user.scss +51 -0
- data/app/pb_kits/playbook/pb_user/docs/_user_default.html.erb +41 -0
- data/app/pb_kits/playbook/pb_user/docs/_user_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_user/docs/_user_size.html.erb +35 -0
- data/app/pb_kits/playbook/pb_user/docs/_user_text_only.html.erb +17 -0
- data/app/pb_kits/playbook/pb_user/docs/_user_vertical_size.html.erb +33 -0
- data/app/pb_kits/playbook/pb_user/docs/example.yml +11 -0
- data/app/pb_kits/playbook/pb_user/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_user/user.rb +117 -0
- data/app/pb_kits/playbook/pb_user_badge/_user_badge.html.erb +8 -0
- data/app/pb_kits/playbook/pb_user_badge/_user_badge.jsx +21 -0
- data/app/pb_kits/playbook/pb_user_badge/_user_badge.scss +24 -0
- data/app/pb_kits/playbook/pb_user_badge/badges/_million-dollar.html.erb +88 -0
- data/app/pb_kits/playbook/pb_user_badge/badges/_veteran.html.erb +17 -0
- data/app/pb_kits/playbook/pb_user_badge/docs/_user_badge_default.html.erb +11 -0
- data/app/pb_kits/playbook/pb_user_badge/docs/_user_badge_default.jsx +12 -0
- data/app/pb_kits/playbook/pb_user_badge/docs/_user_badge_size.html.erb +18 -0
- data/app/pb_kits/playbook/pb_user_badge/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_user_badge/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_user_badge/user_badge.rb +62 -0
- data/app/pb_kits/playbook/pb_vertical_nav/_item.html.erb +4 -4
- data/app/pb_kits/playbook/pb_vertical_nav/_vertical_nav.scss +10 -11
- data/app/pb_kits/playbook/pb_vertical_nav/docs/_block_nav.html.erb +5 -0
- data/app/pb_kits/playbook/pb_vertical_nav/docs/_default_nav.html.erb +3 -3
- data/app/pb_kits/playbook/pb_vertical_nav/docs/example.yml +1 -0
- data/app/pb_kits/playbook/pb_vertical_nav/item.rb +28 -29
- data/app/pb_kits/playbook/pb_vertical_nav/vertical_nav.rb +18 -13
- data/app/pb_kits/playbook/tokens/_border_radius.scss +33 -0
- data/app/pb_kits/playbook/tokens/_colors.scss +35 -248
- data/app/pb_kits/playbook/tokens/_line_height.scss +9 -0
- data/app/pb_kits/playbook/tokens/_opacity.scss +12 -0
- data/app/pb_kits/playbook/tokens/_positioning.scss +11 -0
- data/app/pb_kits/playbook/tokens/_shadows.scss +14 -5
- data/app/pb_kits/playbook/tokens/_spacing.scss +0 -1
- data/app/pb_kits/playbook/tokens/_transition.scss +1 -0
- data/app/pb_kits/playbook/tokens/{_typography.sass → _typography.scss} +25 -0
- data/app/views/layouts/playbook/_nav.html.slim +4 -1
- data/app/views/layouts/playbook/_sidebar.html.slim +1 -1
- data/app/views/layouts/playbook/application.html.slim +7 -3
- data/app/views/playbook/pages/kit_show.html.slim +1 -1
- data/app/views/playbook/pages/principals/_getting_started.html.md +22 -4
- data/app/views/playbook/pages/tokens/_pb_doc_spacing.html.slim +2 -1
- data/app/views/playbook/pages/utilities/_pb_doc_color.html.slim +2 -1
- data/lib/generators/kit/USAGE +2 -29
- data/lib/generators/kit/kit_generator.rb +78 -71
- data/lib/generators/kit/templates/kit_example_rails.erb.tt +1 -0
- data/lib/generators/kit/templates/kit_example_react.erb.tt +12 -0
- data/lib/generators/kit/templates/kit_example_yml.erb.tt +9 -0
- data/lib/generators/kit/templates/kit_html.erb.tt +6 -0
- data/lib/generators/kit/templates/kit_js.erb.tt +1 -0
- data/lib/generators/kit/templates/kit_jsx.erb.tt +21 -0
- data/lib/generators/kit/templates/kit_pack.erb.tt +4 -0
- data/lib/generators/kit/templates/kit_ruby.erb.tt +32 -0
- data/lib/generators/kit/templates/kit_scss.erb +3 -0
- data/lib/playbook.rb +2 -0
- data/lib/playbook/engine.rb +15 -14
- data/lib/playbook/version.rb +3 -1
- data/lib/tasks/db.rake +2 -0
- data/lib/tasks/playbook_tasks.rake +9 -7
- metadata +332 -227
- data/app/pb_kits/playbook/pb_button/_variations.json +0 -15
- data/app/pb_kits/playbook/pb_button/docs/_button_dark.html.erb +0 -3
- data/app/pb_kits/playbook/pb_button/docs/_button_light.html.erb +0 -3
- data/app/pb_kits/playbook/pb_button/docs/_button_sizes.html.erb +0 -3
- data/app/pb_kits/playbook/pb_caption/_caption_lg.scss +0 -5
- data/app/pb_kits/playbook/tokens/_border_radius.sass +0 -27
- data/components/Avatar/Avatar.jsx +0 -96
- data/components/Avatar/AvatarStory.jsx +0 -19
- data/components/Avatar/styles.scss +0 -54
- data/components/Avatar/styles.scss.flow +0 -14
- data/components/Badge/Badge.jsx +0 -40
- data/components/Badge/BadgeStory.jsx +0 -40
- data/components/Badge/badges.scss +0 -167
- data/components/Badge/labels.scss +0 -121
- data/components/Badge/styles.scss +0 -4
- data/components/Badge/styles.scss.flow +0 -38
- data/components/Banner/Banner.jsx +0 -54
- data/components/Banner/BannerStory.jsx +0 -22
- data/components/Banner/styles.scss +0 -75
- data/components/Banner/styles.scss.flow +0 -19
- data/components/Button/Button.jsx +0 -75
- data/components/Button/ButtonStory.jsx +0 -94
- data/components/Capping/CappingStory.jsx +0 -21
- data/components/Card/Card.jsx +0 -44
- data/components/Card/CardStory.jsx +0 -19
- data/components/CircleButton/CircleButton.jsx +0 -51
- data/components/CircleButton/CircleButtonStory.jsx +0 -25
- data/components/CircleButton/styles.scss +0 -33
- data/components/CircleButton/styles.scss.flow +0 -6
- data/components/CollapsibleCard/CollapsibleCard.jsx +0 -108
- data/components/CollapsibleCard/CollapsibleCardStory.jsx +0 -26
- data/components/Color/Color.jsx +0 -55
- data/components/Color/ColorStory.jsx +0 -16
- data/components/Color/styles.scss +0 -6
- data/components/Color/styles.scss.flow +0 -5
- data/components/ColorPickerInput/ColorPickerInput.jsx +0 -99
- data/components/ColorPickerInput/ColorPickerInputStory.jsx +0 -37
- data/components/ColorPickerInput/colorPickerInput.scss +0 -10
- data/components/ColorPickerInput/colorPickerInput.scss.flow +0 -6
- data/components/DOBInput/index.jsx +0 -35
- data/components/DOBInput/story.jsx +0 -20
- data/components/DOBInput/styles.scss +0 -11
- data/components/DOBInput/styles.scss.flow +0 -7
- data/components/DatePicker/DatePicker.jsx +0 -156
- data/components/DatePicker/DatePickerStory.jsx +0 -22
- data/components/DatePicker/styles.scss +0 -6
- data/components/DatePicker/styles.scss.flow +0 -5
- data/components/DateTimePicker/DateTimePicker.jsx +0 -109
- data/components/DateTimePicker/DateTimePickerStory.jsx +0 -31
- data/components/DateTimePicker/story-styles.scss +0 -3
- data/components/DateTimePicker/story-styles.scss.flow +0 -5
- data/components/DateTimePicker/styles.scss +0 -1
- data/components/DateTimePicker/styles.scss.flow +0 -5
- data/components/Errors/Errors.jsx +0 -38
- data/components/FileCard/FileCard.jsx +0 -183
- data/components/FileCard/FileCardStory.jsx +0 -62
- data/components/FileCard/styles.scss +0 -81
- data/components/FileCard/styles.scss.flow +0 -12
- data/components/Flip/Flip.jsx +0 -50
- data/components/Flip/FlipStory.jsx +0 -85
- data/components/Flip/styles.scss +0 -41
- data/components/Flip/styles.scss.flow +0 -11
- data/components/FlyoutPanel/FlyoutPanel.jsx +0 -34
- data/components/FlyoutPanel/FlyoutPanelStory.jsx +0 -36
- data/components/FlyoutPanel/flyout_panel.scss +0 -33
- data/components/FlyoutPanel/flyout_panel.scss.flow +0 -11
- data/components/Grade/Grade.jsx +0 -55
- data/components/Grade/GradeStory.jsx +0 -18
- data/components/Grade/grade.scss +0 -39
- data/components/Grade/grade.scss.flow +0 -6
- data/components/Highlight/Highlight.jsx +0 -39
- data/components/Highlight/HighlightStory.jsx +0 -22
- data/components/Highlight/styles.scss +0 -24
- data/components/Highlight/styles.scss.flow +0 -17
- data/components/Icon/Icon.jsx +0 -54
- data/components/Icon/IconButtonStory.jsx +0 -20
- data/components/Icon/IconStory.jsx +0 -25
- data/components/IconToggle/IconToggle.jsx +0 -56
- data/components/IconToggle/IconToggleStory.jsx +0 -24
- data/components/Milestones/MilestoneItem.jsx +0 -47
- data/components/Milestones/MilestoneItemStory.jsx +0 -25
- data/components/Milestones/Milestones.jsx +0 -51
- data/components/Milestones/MilestonesStory.jsx +0 -30
- data/components/Milestones/milestones.scss +0 -19
- data/components/Milestones/milestones.scss.flow +0 -7
- data/components/Milestones/milestones_item.scss +0 -157
- data/components/Milestones/milestones_item.scss.flow +0 -13
- data/components/Milestones/milestones_variables.scss +0 -11
- data/components/Modal/ModalStory.jsx +0 -29
- data/components/MonogramAvatar/MonogramAvatar.jsx +0 -91
- data/components/MonogramAvatar/MonogramAvatarStory.jsx +0 -21
- data/components/MonogramAvatar/monogram_avatar.scss +0 -54
- data/components/MonogramAvatar/monogram_avatar.scss.flow +0 -10
- data/components/Panel/Panel.jsx +0 -159
- data/components/Panel/PanelStory.jsx +0 -23
- data/components/Panel/panel.scss +0 -32
- data/components/Panel/panel.scss.flow +0 -12
- data/components/PanelGroup/PanelGroup.jsx +0 -121
- data/components/PanelGroup/PanelGroup.scss +0 -96
- data/components/PanelGroup/PanelGroup.scss.flow +0 -6
- data/components/PanelGroup/PanelGroupStory.jsx +0 -112
- data/components/SearchCollectionSelect/SearchCollectionSelect.jsx +0 -29
- data/components/SearchCollectionSelect/SearchCollectionSelectStory.jsx +0 -48
- data/components/SideModal/SideModalStory.jsx +0 -31
- data/components/Spinner/Spinner.jsx +0 -80
- data/components/Spinner/SpinnerStory.jsx +0 -21
- data/components/Spinner/spinner.scss +0 -6
- data/components/Spinner/spinner.scss.flow +0 -5
- data/components/StepMeter/StepMeter.jsx +0 -75
- data/components/StepMeter/StepMeterStory.jsx +0 -25
- data/components/StepMeter/step_meter.scss +0 -120
- data/components/StepMeter/step_meter.scss.flow +0 -9
- data/components/Survey/Survey.jsx +0 -190
- data/components/Survey/SurveyStory.jsx +0 -125
- data/components/Survey/survey.scss +0 -75
- data/components/Survey/survey.scss.flow +0 -11
- data/components/Tab/Tab.jsx +0 -70
- data/components/Tab/tab.scss +0 -25
- data/components/Tab/tab.scss.flow +0 -6
- data/components/TabList/TabList.jsx +0 -35
- data/components/TabList/TabListStory.jsx +0 -31
- data/components/TabList/tabList.scss +0 -5
- data/components/TabList/tabList.scss.flow +0 -5
- data/components/Text/Text.jsx +0 -53
- data/components/Text/TextStory.jsx +0 -23
- data/components/Text/styles.scss +0 -3
- data/components/Text/styles.scss.flow +0 -123
- data/components/Text/text.scss +0 -35
- data/components/TextInput/TextInput.jsx +0 -95
- data/components/TextInput/TextInputStory.jsx +0 -23
- data/components/TextInput/form-control.scss +0 -96
- data/components/TextInput/styles.scss +0 -3
- data/components/TextInput/styles.scss.flow +0 -7
- data/components/TimePicker/TimePicker.jsx +0 -218
- data/components/TimePicker/TimePickerStory.jsx +0 -22
- data/components/TimePicker/styles.scss +0 -1
- data/components/TimePicker/styles.scss.flow +0 -5
- data/components/ToggleButton/ToggleButton.jsx +0 -68
- data/components/ToggleButton/ToggleButtonStory.jsx +0 -46
- data/components/ToggleButton/toggleButton.scss +0 -70
- data/components/ToggleButton/toggleButton.scss.flow +0 -14
- data/components/UserStamp/UserStamp.jsx +0 -40
- data/components/UserStamp/UserStampStory.jsx +0 -22
- data/components/UserStamp/styles.scss +0 -6
- data/components/UserStamp/styles.scss.flow +0 -7
- data/components/Wip/Wip.jsx +0 -34
- data/components/index.js +0 -33
- data/components/types.js +0 -21
- data/lib/generators/kit/templates/html.erb +0 -3
- data/lib/generators/kit/templates/javascript.erb +0 -4
- data/lib/generators/kit/templates/logo.txt +0 -28
- data/lib/generators/kit/templates/ruby.erb +0 -48
- data/lib/generators/kit/templates/scss.erb +0 -0
- data/lib/generators/kit/templates/storyrails.erb +0 -2
- data/lib/generators/kit/templates/storyreact.erb +0 -2
- data/lib/generators/kit/templates/variations.erb +0 -10
@@ -0,0 +1,21 @@
|
|
1
|
+
import React from 'react';
|
2
|
+
import PropTypes from "prop-types";
|
3
|
+
|
4
|
+
const propTypes = {
|
5
|
+
className: PropTypes.string,
|
6
|
+
id: PropTypes.string
|
7
|
+
};
|
8
|
+
|
9
|
+
class UserBadge extends React.Component {
|
10
|
+
render() {
|
11
|
+
return (
|
12
|
+
<div className="pb_user_badge">
|
13
|
+
<span>USER BADGE CONTENT</span>
|
14
|
+
</div>
|
15
|
+
)
|
16
|
+
}
|
17
|
+
}
|
18
|
+
|
19
|
+
UserBadge.propTypes = propTypes;
|
20
|
+
|
21
|
+
export default UserBadge;
|
@@ -0,0 +1,24 @@
|
|
1
|
+
$badge-sizes: (
|
2
|
+
"sm": 16px,
|
3
|
+
"md": 26px,
|
4
|
+
"lg": 36px
|
5
|
+
);
|
6
|
+
|
7
|
+
[class^=pb_user_badge] {
|
8
|
+
.pb__user_badge_wrapper {
|
9
|
+
svg,
|
10
|
+
img {
|
11
|
+
width: 100%;
|
12
|
+
height: 100%;
|
13
|
+
}
|
14
|
+
}
|
15
|
+
|
16
|
+
@each $name, $size in $badge-sizes {
|
17
|
+
&[class*=_#{$name}] {
|
18
|
+
.pb__user_badge_wrapper {
|
19
|
+
width: $size;
|
20
|
+
height: $size;
|
21
|
+
}
|
22
|
+
}
|
23
|
+
}
|
24
|
+
}
|
@@ -0,0 +1,88 @@
|
|
1
|
+
|
2
|
+
<?xml version="1.0" encoding="utf-8"?>
|
3
|
+
<!-- Generator: Adobe Illustrator 20.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
4
|
+
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
5
|
+
viewBox="0 0 242.9 242.9" style="enable-background:new 0 0 242.9 242.9;" xml:space="preserve">
|
6
|
+
<style type="text/css">
|
7
|
+
.st0{fill:url(#SVGID_1_);}
|
8
|
+
.st1{fill:url(#SVGID_2_);}
|
9
|
+
.st2{fill:url(#SVGID_3_);}
|
10
|
+
.st3{fill:url(#SVGID_4_);}
|
11
|
+
.st4{fill:url(#SVGID_5_);}
|
12
|
+
.st5{fill:url(#SVGID_6_);}
|
13
|
+
</style>
|
14
|
+
<circle cx="121.5" cy="121.5" r="121.5"/>
|
15
|
+
<g>
|
16
|
+
<g>
|
17
|
+
<linearGradient id="SVGID_1_" gradientUnits="userSpaceOnUse" x1="42.4829" y1="35.6453" x2="200.3093" y2="35.6453">
|
18
|
+
<stop offset="0" style="stop-color:#E6B711"/>
|
19
|
+
<stop offset="0.1282" style="stop-color:#EAC23C"/>
|
20
|
+
<stop offset="0.2778" style="stop-color:#EECC66"/>
|
21
|
+
<stop offset="0.4129" style="stop-color:#F1D485"/>
|
22
|
+
<stop offset="0.5273" style="stop-color:#F2D998"/>
|
23
|
+
<stop offset="0.6073" style="stop-color:#F3DB9F"/>
|
24
|
+
<stop offset="1" style="stop-color:#E6B711"/>
|
25
|
+
</linearGradient>
|
26
|
+
<path class="st0" d="M56.4,53.8c16.9-16.2,39.8-26.2,65-26.2c25.2,0,48.1,10,64.9,26.2l14,0c-19.1-22.2-47.4-36.3-78.9-36.3
|
27
|
+
c-31.5,0-59.8,14.1-78.9,36.3H56.4z"/>
|
28
|
+
<linearGradient id="SVGID_2_" gradientUnits="userSpaceOnUse" x1="17.407" y1="132.1794" x2="44.8973" y2="132.1794">
|
29
|
+
<stop offset="0" style="stop-color:#E6B711"/>
|
30
|
+
<stop offset="0.1282" style="stop-color:#EAC23C"/>
|
31
|
+
<stop offset="0.2778" style="stop-color:#EECC66"/>
|
32
|
+
<stop offset="0.4129" style="stop-color:#F1D485"/>
|
33
|
+
<stop offset="0.5273" style="stop-color:#F2D998"/>
|
34
|
+
<stop offset="0.6073" style="stop-color:#F3DB9F"/>
|
35
|
+
<stop offset="1" style="stop-color:#E6B711"/>
|
36
|
+
</linearGradient>
|
37
|
+
<path class="st1" d="M44.9,175.7c-10.9-15.3-17.3-34-17.3-54.2c0-14.1,3.1-27.5,8.8-39.5l-11.1,0c-5,12.2-7.8,25.5-7.8,39.5
|
38
|
+
c0,22.7,7.3,43.8,19.8,60.9L44.9,175.7z"/>
|
39
|
+
<linearGradient id="SVGID_3_" gradientUnits="userSpaceOnUse" x1="52.9143" y1="212.5732" x2="189.7151" y2="212.5732">
|
40
|
+
<stop offset="0" style="stop-color:#E6B711"/>
|
41
|
+
<stop offset="0.1282" style="stop-color:#EAC23C"/>
|
42
|
+
<stop offset="0.2778" style="stop-color:#EECC66"/>
|
43
|
+
<stop offset="0.4129" style="stop-color:#F1D485"/>
|
44
|
+
<stop offset="0.5273" style="stop-color:#F2D998"/>
|
45
|
+
<stop offset="0.6073" style="stop-color:#F3DB9F"/>
|
46
|
+
<stop offset="1" style="stop-color:#E6B711"/>
|
47
|
+
</linearGradient>
|
48
|
+
<path class="st2" d="M173,199.8c-14.8,9.8-32.5,15.5-51.6,15.5c-19.1,0-37-5.8-51.8-15.6H52.9c18.3,16.1,42.3,25.8,68.5,25.8
|
49
|
+
c26.1,0,50-9.7,68.3-25.7H173z"/>
|
50
|
+
<linearGradient id="SVGID_4_" gradientUnits="userSpaceOnUse" x1="31.1232" y1="136.1588" x2="207.7658" y2="136.1588">
|
51
|
+
<stop offset="0" style="stop-color:#E6B711"/>
|
52
|
+
<stop offset="0.1282" style="stop-color:#EAC23C"/>
|
53
|
+
<stop offset="0.2778" style="stop-color:#EECC66"/>
|
54
|
+
<stop offset="0.4129" style="stop-color:#F1D485"/>
|
55
|
+
<stop offset="0.5273" style="stop-color:#F2D998"/>
|
56
|
+
<stop offset="0.6073" style="stop-color:#F3DB9F"/>
|
57
|
+
<stop offset="1" style="stop-color:#E6B711"/>
|
58
|
+
</linearGradient>
|
59
|
+
<path class="st3" d="M139.2,193v-1.8c5-0.4,10.2-0.5,13.4-5c3.8-5.2,3.2-15.4,3.2-21.5V78.5l-47.3,120.4L61.2,81.2v61.1
|
60
|
+
c0,13.6,0.5,35.1,12.5,44.2c4.3,3.2,9,3.9,14.2,4.7v1.8H31.1v-1.8c1.6-0.4,3.2-0.7,4.8-1.1c22.6-5.7,22.9-32.4,22.9-51.1v-37.8
|
61
|
+
c0-6.1,0.5-13.3-3.2-18.5c-4.5-6.1-13.4-7.2-20.4-7.5v-1.8H96l29.6,75.4l29.9-75.4h52.3v1.8c-4.8,0.4-10.2,0.9-13.4,5
|
62
|
+
c-3.8,4.8-3.2,15.9-3.2,21.9v62.5c0,6.3-0.7,16.1,3.2,21.5c3.2,4.3,6.2,4.7,11.2,5v1.8H139.2z"/>
|
63
|
+
</g>
|
64
|
+
<linearGradient id="SVGID_5_" gradientUnits="userSpaceOnUse" x1="30.4528" y1="63.629" x2="213.7944" y2="63.629">
|
65
|
+
<stop offset="0" style="stop-color:#E6B711"/>
|
66
|
+
<stop offset="0.1282" style="stop-color:#EAC23C"/>
|
67
|
+
<stop offset="0.2778" style="stop-color:#EECC66"/>
|
68
|
+
<stop offset="0.4129" style="stop-color:#F1D485"/>
|
69
|
+
<stop offset="0.5273" style="stop-color:#F2D998"/>
|
70
|
+
<stop offset="0.6073" style="stop-color:#F3DB9F"/>
|
71
|
+
<stop offset="1" style="stop-color:#E6B711"/>
|
72
|
+
</linearGradient>
|
73
|
+
<rect x="30.5" y="60.6" class="st4" width="183.3" height="6.1"/>
|
74
|
+
<g>
|
75
|
+
<linearGradient id="SVGID_6_" gradientUnits="userSpaceOnUse" x1="196.6758" y1="132.9232" x2="225.5378" y2="132.9232">
|
76
|
+
<stop offset="0" style="stop-color:#E6B711"/>
|
77
|
+
<stop offset="0.1282" style="stop-color:#EAC23C"/>
|
78
|
+
<stop offset="0.2778" style="stop-color:#EECC66"/>
|
79
|
+
<stop offset="0.4129" style="stop-color:#F1D485"/>
|
80
|
+
<stop offset="0.5273" style="stop-color:#F2D998"/>
|
81
|
+
<stop offset="0.6073" style="stop-color:#F3DB9F"/>
|
82
|
+
<stop offset="1" style="stop-color:#E6B711"/>
|
83
|
+
</linearGradient>
|
84
|
+
<path class="st5" d="M196.7,177.5c11.5-15.6,18.7-35.2,18.7-56c0-14.1-3.1-27.5-8.8-39.5l11.1,0c5,12.2,7.8,25.5,7.8,39.5
|
85
|
+
c0,23.4-7.8,45-20.9,62.4L196.7,177.5z"/>
|
86
|
+
</g>
|
87
|
+
</g>
|
88
|
+
</svg>
|
@@ -0,0 +1,17 @@
|
|
1
|
+
<style type="text/css">
|
2
|
+
.veteran-st0{fill:#004876;}
|
3
|
+
.veteran-st1{fill:#FFFFFF;}
|
4
|
+
.veteran-st2{fill:#BB2432;}
|
5
|
+
</style>
|
6
|
+
|
7
|
+
<?xml version="1.0" encoding="utf-8"?>
|
8
|
+
<!-- Generator: Adobe Illustrator 20.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
|
9
|
+
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
|
10
|
+
viewBox="0 0 198.6 242.9" style="enable-background:new 0 0 198.6 242.9;" xml:space="preserve">
|
11
|
+
<path class="veteran-st0" d="M198.4,71.5c0-0.2,0-0.4,0-0.5c-0.2-1.2-1.4-2.1-1.4-2.1L103.2,2.7c-0.7-0.4-1-0.6-1.6-0.6
|
12
|
+
c-1.3,0-2.3,1-2.3,2.3c0,0.1,0,56.1,0,67.1h-0.6v29.6h99.8L198.4,71.5L198.4,71.5z"/>
|
13
|
+
<path class="veteran-st1" d="M172.9,159.2c-31.4,23-33.2,24.3-33.2,24.3l-40.5,3.2v-29.4L172.9,159.2z"/>
|
14
|
+
<path class="veteran-st2" d="M99.3,125.4V33.5L1.6,102.7l-0.1,0.1c-1,0.7-1.5,1.8-1.5,3v0v67.4v0c0,1.2,0.6,2.3,1.5,3l0.1,0.1l93.5,66.3
|
15
|
+
c1.7,1.2,4.1,0,4.1-2.1v-28.9l40.5-28l-40.5,0.7v-25h73.7l25.4-16.9l0.2-16.8H99.3z"/>
|
16
|
+
<rect x="99.3" y="101.1" class="veteran-st1" width="99.3" height="24.3"/>
|
17
|
+
</svg>
|
@@ -0,0 +1,18 @@
|
|
1
|
+
<%= pb_rails("user_badge", props: {
|
2
|
+
badge: "veteran",
|
3
|
+
size: "sm"
|
4
|
+
}) %>
|
5
|
+
|
6
|
+
<br><br>
|
7
|
+
|
8
|
+
<%= pb_rails("user_badge", props: {
|
9
|
+
badge: "veteran",
|
10
|
+
size: "md"
|
11
|
+
}) %>
|
12
|
+
|
13
|
+
<br><br>
|
14
|
+
|
15
|
+
<%= pb_rails("user_badge", props: {
|
16
|
+
badge: "veteran",
|
17
|
+
size: "lg"
|
18
|
+
}) %>
|
@@ -0,0 +1 @@
|
|
1
|
+
export {default as UserBadgeDefault} from './_user_badge_default.jsx';
|
@@ -0,0 +1,62 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
include ActionView::Helpers::AssetTagHelper
|
4
|
+
|
5
|
+
module Playbook
|
6
|
+
module PbUserBadge
|
7
|
+
class UserBadge < Playbook::PbKit::Base
|
8
|
+
PROPS = %i[configured_badge
|
9
|
+
configured_classname
|
10
|
+
configured_data
|
11
|
+
configured_id
|
12
|
+
configured_size].freeze
|
13
|
+
|
14
|
+
def initialize(badge: default_configuration,
|
15
|
+
classname: default_configuration,
|
16
|
+
data: default_configuration,
|
17
|
+
id: default_configuration,
|
18
|
+
size: default_configuration)
|
19
|
+
self.configured_badge = badge
|
20
|
+
self.configured_classname = classname
|
21
|
+
self.configured_data = data
|
22
|
+
self.configured_id = id
|
23
|
+
self.configured_size = size
|
24
|
+
end
|
25
|
+
|
26
|
+
def display_badge
|
27
|
+
"playbook/pb_user_badge/badges/#{badge}" if is_set? configured_badge
|
28
|
+
end
|
29
|
+
|
30
|
+
def kit_class
|
31
|
+
kit_options = [
|
32
|
+
"pb_user_badge",
|
33
|
+
size,
|
34
|
+
]
|
35
|
+
kit_options.join("_")
|
36
|
+
end
|
37
|
+
|
38
|
+
def to_partial_path
|
39
|
+
"pb_user_badge/user_badge"
|
40
|
+
end
|
41
|
+
|
42
|
+
private
|
43
|
+
|
44
|
+
def badge
|
45
|
+
badge_options = %w[million-dollar veteran]
|
46
|
+
one_of_value(configured_badge, badge_options, "million-dollar")
|
47
|
+
end
|
48
|
+
|
49
|
+
def size
|
50
|
+
size_options = %w[sm md lg]
|
51
|
+
one_of_value(configured_size, size_options, "md")
|
52
|
+
end
|
53
|
+
|
54
|
+
DEFAULT = Object.new
|
55
|
+
private_constant :DEFAULT
|
56
|
+
def default_configuration
|
57
|
+
DEFAULT
|
58
|
+
end
|
59
|
+
attr_accessor(*PROPS)
|
60
|
+
end
|
61
|
+
end
|
62
|
+
end
|
@@ -1,8 +1,8 @@
|
|
1
1
|
<%= content_tag(:li,
|
2
2
|
id: object.id,
|
3
3
|
data: object.data,
|
4
|
-
class: object.classname("vertical_nav_list_border_item#{object.
|
5
|
-
|
6
|
-
|
7
|
-
|
4
|
+
class: object.classname("vertical_nav_list_border_item#{object.active_class}")) do %>
|
5
|
+
<a href=<%= object.link %> class="vertical_nav_list_item_link">
|
6
|
+
<span class="vertical_nav_list_item_link_text"><%= object.text %><%= object.yield(context: self) %></span>
|
7
|
+
</a>
|
8
8
|
<% end %>
|
@@ -3,7 +3,6 @@
|
|
3
3
|
@import "../tokens/colors";
|
4
4
|
|
5
5
|
// Another style should be borders like buttons
|
6
|
-
|
7
6
|
.vertical_nav_list {
|
8
7
|
$selector: ".vertical_nav_list";
|
9
8
|
&_title {
|
@@ -16,7 +15,7 @@
|
|
16
15
|
}
|
17
16
|
&_border_item {
|
18
17
|
list-style: none;
|
19
|
-
border-bottom: 1px solid $
|
18
|
+
border-bottom: 1px solid $border_light;
|
20
19
|
&:last-child {
|
21
20
|
border-bottom: 0;
|
22
21
|
}
|
@@ -25,15 +24,15 @@
|
|
25
24
|
&_border_item {
|
26
25
|
&_active,
|
27
26
|
&.active {
|
28
|
-
background-color: $
|
27
|
+
background-color: $active_light;
|
29
28
|
#{$selector}_item_link,
|
30
29
|
#{$selector}_border_item_link {
|
31
|
-
border-color: $
|
30
|
+
border-color: $primary;
|
32
31
|
&_icon {
|
33
|
-
color: $
|
32
|
+
color: $primary;
|
34
33
|
}
|
35
34
|
&_text {
|
36
|
-
color: $
|
35
|
+
color: $primary;
|
37
36
|
}
|
38
37
|
}
|
39
38
|
}
|
@@ -50,22 +49,22 @@
|
|
50
49
|
&_icon {
|
51
50
|
font-size: $font_large;
|
52
51
|
margin-right: $space_sm;
|
53
|
-
color: $
|
52
|
+
color: $text_lt_lighter;
|
54
53
|
}
|
55
54
|
&_text {
|
56
55
|
font-size: $font_base;
|
57
56
|
font-weight: $bold;
|
58
|
-
color: $
|
57
|
+
color: $text_lt_default;
|
59
58
|
}
|
60
59
|
&:hover {
|
61
|
-
background-color: rgba($
|
60
|
+
background-color: rgba($primary, 0.03);
|
62
61
|
#{$selector}_item_link_icon,
|
63
62
|
#{$selector}_border_item_link_icon {
|
64
|
-
color: $
|
63
|
+
color: $primary;
|
65
64
|
}
|
66
65
|
#{$selector}_item_link_text,
|
67
66
|
#{$selector}_border_item_link_text {
|
68
|
-
color: $
|
67
|
+
color: $primary;
|
69
68
|
}
|
70
69
|
}
|
71
70
|
}
|
@@ -0,0 +1,5 @@
|
|
1
|
+
<%= pb_rails("vertical_nav", props: {title: "Title Example", link: "#"}) do %>
|
2
|
+
<%= pb_rails("vertical_nav/item", props: { link: "#", active: true }) do%>Active Nav Item using block<% end %>
|
3
|
+
<%= pb_rails("vertical_nav/item", props: { link: "#" }) do%>Nav Item using block<% end %>
|
4
|
+
<%= pb_rails("vertical_nav/item", props: { link: "#" }) do%>Nav Item using block<% end %>
|
5
|
+
<% end %>
|
@@ -1,5 +1,5 @@
|
|
1
1
|
<%= pb_rails("vertical_nav", props: {title: "Title Example", link: "#"}) do %>
|
2
|
-
<%= pb_rails("vertical_nav/item", props: { text: "Active Nav Item", link: "#", active: true }) %>
|
3
|
-
<%= pb_rails("vertical_nav/item", props: { text: "Nav Item", link: "#" }) %>
|
4
|
-
<%= pb_rails("vertical_nav/item", props: { text: "Nav Item", link: "#" }) %>
|
2
|
+
<%= pb_rails("vertical_nav/item", props: { text: "Active Nav Item using text prop", link: "#", active: true }) %>
|
3
|
+
<%= pb_rails("vertical_nav/item", props: { text: "Nav Item using text prop", link: "#" }) %>
|
4
|
+
<%= pb_rails("vertical_nav/item", props: { text: "Nav Item using text prop", link: "#" }) %>
|
5
5
|
<% end %>
|
@@ -1,51 +1,50 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Playbook
|
2
4
|
module PbVerticalNav
|
3
5
|
class Item < Playbook::PbKit::Base
|
4
|
-
PROPS = [
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
|
6
|
+
PROPS = %i[configured_active
|
7
|
+
configured_classname
|
8
|
+
configured_data
|
9
|
+
configured_id
|
10
|
+
configured_link
|
11
|
+
configured_text
|
12
|
+
block].freeze
|
10
13
|
|
11
14
|
def initialize(active: default_configuration,
|
12
|
-
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
|
15
|
+
classname: default_configuration,
|
16
|
+
data: default_configuration,
|
17
|
+
id: default_configuration,
|
18
|
+
link: default_configuration,
|
19
|
+
text: default_configuration,
|
20
|
+
&block)
|
17
21
|
self.configured_active = active
|
18
22
|
self.configured_classname = classname
|
19
23
|
self.configured_data = data
|
20
24
|
self.configured_id = id
|
21
25
|
self.configured_link = link
|
22
26
|
self.configured_text = text
|
27
|
+
self.block = block_given? ? block : nil
|
23
28
|
end
|
24
29
|
|
25
30
|
def active
|
26
|
-
|
27
|
-
""
|
28
|
-
else
|
29
|
-
if (configured_active == true)
|
30
|
-
"_active"
|
31
|
-
end
|
32
|
-
end
|
31
|
+
is_true? configured_active
|
33
32
|
end
|
34
33
|
|
35
|
-
def
|
36
|
-
if
|
37
|
-
"#"
|
38
|
-
else
|
39
|
-
configured_link
|
40
|
-
end
|
34
|
+
def active_class
|
35
|
+
"_active" if active == true
|
41
36
|
end
|
42
37
|
|
43
38
|
def text
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
39
|
+
default_value(configured_text, "")
|
40
|
+
end
|
41
|
+
|
42
|
+
def link
|
43
|
+
default_value(configured_link, "#")
|
44
|
+
end
|
45
|
+
|
46
|
+
def yield(context:)
|
47
|
+
!block.nil? ? context.capture(&block) : ""
|
49
48
|
end
|
50
49
|
|
51
50
|
def to_partial_path
|