playbook_ui 2.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/README.md +316 -0
- data/Rakefile +32 -0
- data/app/assets/config/playbook_manifest.js +2 -0
- data/app/assets/images/clark.jpg +0 -0
- data/app/assets/images/giant.jpg +0 -0
- data/app/assets/images/pb-caret.svg +1 -0
- data/app/assets/images/pb-check.svg +11 -0
- data/app/controllers/playbook/application_controller.rb +10 -0
- data/app/controllers/playbook/guides_controller.rb +8 -0
- data/app/controllers/playbook/pages_controller.rb +50 -0
- data/app/helpers/playbook/application_helper.rb +19 -0
- data/app/helpers/playbook/layout_helper.rb +7 -0
- data/app/helpers/playbook/pb_doc_helper.rb +68 -0
- data/app/helpers/playbook/pb_kit_helper.rb +45 -0
- data/app/helpers/playbook/redcarpet_helper.rb +154 -0
- data/app/pb_kits/playbook/config/_kit_example.html.slim +5 -0
- data/app/pb_kits/playbook/config/_kit_ui.html.slim +24 -0
- data/app/pb_kits/playbook/config/_pb_kit_api.html.erb +18 -0
- data/app/pb_kits/playbook/packs/application.js +12 -0
- data/app/pb_kits/playbook/packs/examples.js +37 -0
- data/app/pb_kits/playbook/packs/kits.js +11 -0
- data/app/pb_kits/playbook/packs/main.scss +9 -0
- data/app/pb_kits/playbook/packs/pb_avatar.js +4 -0
- data/app/pb_kits/playbook/packs/pb_body.js +4 -0
- data/app/pb_kits/playbook/packs/pb_button.js +4 -0
- data/app/pb_kits/playbook/packs/pb_caption.js +4 -0
- data/app/pb_kits/playbook/packs/pb_card.js +4 -0
- data/app/pb_kits/playbook/packs/pb_image.js +6 -0
- data/app/pb_kits/playbook/packs/pb_input.js +4 -0
- data/app/pb_kits/playbook/packs/pb_layout.js +4 -0
- data/app/pb_kits/playbook/packs/pb_list.js +4 -0
- data/app/pb_kits/playbook/packs/pb_table.js +16 -0
- data/app/pb_kits/playbook/packs/pb_title.js +4 -0
- data/app/pb_kits/playbook/packs/pb_vertical_nav.js +4 -0
- data/app/pb_kits/playbook/packs/site_styles/_kit_style_index.scss +13 -0
- data/app/pb_kits/playbook/packs/site_styles/_scaffold.scss +43 -0
- data/app/pb_kits/playbook/packs/site_styles/_site-style.scss +72 -0
- data/app/pb_kits/playbook/packs/site_styles/docs/_all.scss +8 -0
- data/app/pb_kits/playbook/packs/site_styles/docs/_code_snippet.scss +531 -0
- data/app/pb_kits/playbook/packs/site_styles/docs/_color_utilities.scss +90 -0
- data/app/pb_kits/playbook/packs/site_styles/docs/_kit_doc.scss +173 -0
- data/app/pb_kits/playbook/packs/site_styles/docs/_kits_examples.scss +22 -0
- data/app/pb_kits/playbook/packs/site_styles/docs/_markdown.scss +82 -0
- data/app/pb_kits/playbook/packs/site_styles/docs/_spacing_tokens.scss +72 -0
- data/app/pb_kits/playbook/pb_avatar/_avatar.html.erb +8 -0
- data/app/pb_kits/playbook/pb_avatar/_avatar.jsx +62 -0
- data/app/pb_kits/playbook/pb_avatar/_avatar.scss +49 -0
- data/app/pb_kits/playbook/pb_avatar/avatar.rb +82 -0
- data/app/pb_kits/playbook/pb_avatar/docs/_avatar_default.html.erb +5 -0
- data/app/pb_kits/playbook/pb_avatar/docs/_avatar_default.jsx +16 -0
- data/app/pb_kits/playbook/pb_avatar/docs/_avatar_monogram.html.erb +5 -0
- data/app/pb_kits/playbook/pb_avatar/docs/_avatar_monogram.jsx +16 -0
- data/app/pb_kits/playbook/pb_avatar/docs/example.yml +7 -0
- data/app/pb_kits/playbook/pb_avatar/docs/index.js +2 -0
- data/app/pb_kits/playbook/pb_body/_body.html.erb +4 -0
- data/app/pb_kits/playbook/pb_body/_body.jsx +36 -0
- data/app/pb_kits/playbook/pb_body/_body.scss +37 -0
- data/app/pb_kits/playbook/pb_body/body.rb +76 -0
- data/app/pb_kits/playbook/pb_body/docs/_body_dark.html.erb +3 -0
- data/app/pb_kits/playbook/pb_body/docs/_body_dark.jsx +14 -0
- data/app/pb_kits/playbook/pb_body/docs/_body_light.html.erb +3 -0
- data/app/pb_kits/playbook/pb_body/docs/_body_light.jsx +14 -0
- data/app/pb_kits/playbook/pb_body/docs/example.yml +7 -0
- data/app/pb_kits/playbook/pb_body/docs/index.js +2 -0
- data/app/pb_kits/playbook/pb_button/_button.html.erb +9 -0
- data/app/pb_kits/playbook/pb_button/_button.jsx +40 -0
- data/app/pb_kits/playbook/pb_button/_button.scss +53 -0
- data/app/pb_kits/playbook/pb_button/_variations.json +15 -0
- data/app/pb_kits/playbook/pb_button/button.rb +87 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_dark.html.erb +3 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_dark.jsx +14 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_light.html.erb +3 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_light.jsx +14 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_sizes.html.erb +3 -0
- data/app/pb_kits/playbook/pb_button/docs/_button_sizes.jsx +14 -0
- data/app/pb_kits/playbook/pb_button/docs/example.yml +9 -0
- data/app/pb_kits/playbook/pb_button/docs/index.js +3 -0
- data/app/pb_kits/playbook/pb_caption/_caption.html.erb +2 -0
- data/app/pb_kits/playbook/pb_caption/_caption.jsx +39 -0
- data/app/pb_kits/playbook/pb_caption/_caption.scss +5 -0
- data/app/pb_kits/playbook/pb_caption/_caption_lg.scss +5 -0
- data/app/pb_kits/playbook/pb_caption/_caption_mixin.scss +23 -0
- data/app/pb_kits/playbook/pb_caption/caption.rb +78 -0
- data/app/pb_kits/playbook/pb_caption/docs/_caption_dark.html.erb +2 -0
- data/app/pb_kits/playbook/pb_caption/docs/_caption_dark.jsx +13 -0
- data/app/pb_kits/playbook/pb_caption/docs/_caption_light.html.erb +2 -0
- data/app/pb_kits/playbook/pb_caption/docs/_caption_light.jsx +13 -0
- data/app/pb_kits/playbook/pb_caption/docs/example.yml +7 -0
- data/app/pb_kits/playbook/pb_caption/docs/index.js +2 -0
- data/app/pb_kits/playbook/pb_card/_card.html.erb +6 -0
- data/app/pb_kits/playbook/pb_card/_card.jsx +25 -0
- data/app/pb_kits/playbook/pb_card/_card.scss +14 -0
- data/app/pb_kits/playbook/pb_card/card.rb +37 -0
- data/app/pb_kits/playbook/pb_card/docs/_card_light.html.erb +3 -0
- data/app/pb_kits/playbook/pb_card/docs/_card_light.jsx +12 -0
- data/app/pb_kits/playbook/pb_card/docs/example.yml +5 -0
- data/app/pb_kits/playbook/pb_card/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_image/_image.html.erb +5 -0
- data/app/pb_kits/playbook/pb_image/_image.jsx +32 -0
- data/app/pb_kits/playbook/pb_image/_image.scss +15 -0
- data/app/pb_kits/playbook/pb_image/docs/_default_image.html.erb +1 -0
- data/app/pb_kits/playbook/pb_image/docs/_default_image.jsx +12 -0
- data/app/pb_kits/playbook/pb_image/docs/example.yml +5 -0
- data/app/pb_kits/playbook/pb_image/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_image/image.rb +53 -0
- data/app/pb_kits/playbook/pb_input/_input.html.erb +17 -0
- data/app/pb_kits/playbook/pb_input/_input.jsx +57 -0
- data/app/pb_kits/playbook/pb_input/_input.scss +58 -0
- data/app/pb_kits/playbook/pb_input/docs/_input_default.html.erb +5 -0
- data/app/pb_kits/playbook/pb_input/docs/_input_default.jsx +16 -0
- data/app/pb_kits/playbook/pb_input/docs/example.yml +5 -0
- data/app/pb_kits/playbook/pb_input/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_input/input.rb +85 -0
- data/app/pb_kits/playbook/pb_kit/base.rb +38 -0
- data/app/pb_kits/playbook/pb_layout/_body.html.erb +6 -0
- data/app/pb_kits/playbook/pb_layout/_body.jsx +26 -0
- data/app/pb_kits/playbook/pb_layout/_layout.html.erb +6 -0
- data/app/pb_kits/playbook/pb_layout/_layout.jsx +54 -0
- data/app/pb_kits/playbook/pb_layout/_layout.scss +87 -0
- data/app/pb_kits/playbook/pb_layout/_layout_mixin.scss +60 -0
- data/app/pb_kits/playbook/pb_layout/_sidebar.html.erb +6 -0
- data/app/pb_kits/playbook/pb_layout/_sidebar.jsx +26 -0
- data/app/pb_kits/playbook/pb_layout/body.rb +37 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_lg.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_lg_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_md.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_md_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_sm.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_sm_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_xl.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_xl_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_xs.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_xs.jsx +15 -0
- data/app/pb_kits/playbook/pb_layout/docs/_layout_xs_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_layout/docs/example.yml +14 -0
- data/app/pb_kits/playbook/pb_layout/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_layout/layout.rb +109 -0
- data/app/pb_kits/playbook/pb_layout/sidebar.rb +37 -0
- data/app/pb_kits/playbook/pb_list/_item.html.erb +6 -0
- data/app/pb_kits/playbook/pb_list/_list.html.erb +9 -0
- data/app/pb_kits/playbook/pb_list/_list.jsx +56 -0
- data/app/pb_kits/playbook/pb_list/_list.scss +94 -0
- data/app/pb_kits/playbook/pb_list/_list_item.jsx +26 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_borderless.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_dark.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_borderless.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_lg.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_ordered.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_dark_xpadding.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_default.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_default.jsx +16 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_lg.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_ordered.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/_list_xpadding.html.erb +7 -0
- data/app/pb_kits/playbook/pb_list/docs/example.yml +14 -0
- data/app/pb_kits/playbook/pb_list/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_list/item.rb +41 -0
- data/app/pb_kits/playbook/pb_list/list.rb +114 -0
- data/app/pb_kits/playbook/pb_table/_table.html.erb +12 -0
- data/app/pb_kits/playbook/pb_table/_table.jsx +60 -0
- data/app/pb_kits/playbook/pb_table/_table.scss +1 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_container.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_container.jsx +45 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_container_dark.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_container_dark.jsx +46 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_dark.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_dark.jsx +45 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_disable_hover.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_disable_hover.jsx +45 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_lg.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_lg.jsx +43 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_md.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_md.jsx +43 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_multiline.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_multiline.jsx +43 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_single_line.html.erb +48 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_single_line.jsx +45 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_sm.html.erb +34 -0
- data/app/pb_kits/playbook/pb_table/docs/_table_sm.jsx +43 -0
- data/app/pb_kits/playbook/pb_table/docs/example.yml +21 -0
- data/app/pb_kits/playbook/pb_table/docs/index.js +9 -0
- data/app/pb_kits/playbook/pb_table/styles/_all.scss +14 -0
- data/app/pb_kits/playbook/pb_table/styles/_as-cards.scss +49 -0
- data/app/pb_kits/playbook/pb_table/styles/_content.scss +13 -0
- data/app/pb_kits/playbook/pb_table/styles/_headers.scss +17 -0
- data/app/pb_kits/playbook/pb_table/styles/_hover.scss +66 -0
- data/app/pb_kits/playbook/pb_table/styles/_mixins.scss +0 -0
- data/app/pb_kits/playbook/pb_table/styles/_mobile.scss +138 -0
- data/app/pb_kits/playbook/pb_table/styles/_reset.scss +17 -0
- data/app/pb_kits/playbook/pb_table/styles/_single-line.scss +35 -0
- data/app/pb_kits/playbook/pb_table/styles/_structure.scss +39 -0
- data/app/pb_kits/playbook/pb_table/styles/_table-card.scss +88 -0
- data/app/pb_kits/playbook/pb_table/styles/_table-dark.scss +92 -0
- data/app/pb_kits/playbook/pb_table/styles/_variables.scss +23 -0
- data/app/pb_kits/playbook/pb_table/table.rb +95 -0
- data/app/pb_kits/playbook/pb_title/_title.html.erb +1 -0
- data/app/pb_kits/playbook/pb_title/_title.jsx +33 -0
- data/app/pb_kits/playbook/pb_title/_title.scss +32 -0
- data/app/pb_kits/playbook/pb_title/_title_mixin.scss +57 -0
- data/app/pb_kits/playbook/pb_title/docs/_title_dark.html.erb +4 -0
- data/app/pb_kits/playbook/pb_title/docs/_title_dark.jsx +15 -0
- data/app/pb_kits/playbook/pb_title/docs/_title_light.html.erb +4 -0
- data/app/pb_kits/playbook/pb_title/docs/_title_light.jsx +15 -0
- data/app/pb_kits/playbook/pb_title/docs/example.yml +7 -0
- data/app/pb_kits/playbook/pb_title/docs/index.js +2 -0
- data/app/pb_kits/playbook/pb_title/title.rb +76 -0
- data/app/pb_kits/playbook/pb_vertical_nav/_item.html.erb +8 -0
- data/app/pb_kits/playbook/pb_vertical_nav/_item.jsx +34 -0
- data/app/pb_kits/playbook/pb_vertical_nav/_vertical_nav.html.erb +13 -0
- data/app/pb_kits/playbook/pb_vertical_nav/_vertical_nav.jsx +31 -0
- data/app/pb_kits/playbook/pb_vertical_nav/_vertical_nav.scss +73 -0
- data/app/pb_kits/playbook/pb_vertical_nav/docs/_default_nav.html.erb +5 -0
- data/app/pb_kits/playbook/pb_vertical_nav/docs/_default_nav.jsx +15 -0
- data/app/pb_kits/playbook/pb_vertical_nav/docs/example.yml +5 -0
- data/app/pb_kits/playbook/pb_vertical_nav/docs/index.js +1 -0
- data/app/pb_kits/playbook/pb_vertical_nav/item.rb +65 -0
- data/app/pb_kits/playbook/pb_vertical_nav/vertical_nav.rb +59 -0
- data/app/pb_kits/playbook/tokens/_animation-curves.scss +37 -0
- data/app/pb_kits/playbook/tokens/_border_radius.sass +27 -0
- data/app/pb_kits/playbook/tokens/_colors.scss +417 -0
- data/app/pb_kits/playbook/tokens/_fonts.scss +97 -0
- data/app/pb_kits/playbook/tokens/_line_height.scss +7 -0
- data/app/pb_kits/playbook/tokens/_opacity.scss +9 -0
- data/app/pb_kits/playbook/tokens/_positioning.scss +24 -0
- data/app/pb_kits/playbook/tokens/_screen_sizes.scss +30 -0
- data/app/pb_kits/playbook/tokens/_shadows.scss +8 -0
- data/app/pb_kits/playbook/tokens/_spacing.scss +27 -0
- data/app/pb_kits/playbook/tokens/_typography.sass +64 -0
- data/app/pb_kits/playbook/utilities/_background_colors.scss +21 -0
- data/app/pb_kits/playbook/utilities/_colors.scss +26 -0
- data/app/views/layouts/playbook/_nav.html.slim +3 -0
- data/app/views/layouts/playbook/_sidebar.html.slim +29 -0
- data/app/views/layouts/playbook/application.html.slim +18 -0
- data/app/views/layouts/playbook/fullscreen.html.slim +10 -0
- data/app/views/layouts/playbook/grid.html.slim +10 -0
- data/app/views/playbook/guides/create_kit.html.slim +16 -0
- data/app/views/playbook/guides/create_kit/_file_naming.html.md +2 -0
- data/app/views/playbook/guides/create_kit/_generator.html.md +6 -0
- data/app/views/playbook/guides/create_kit/_kit_examples.html.md +2 -0
- data/app/views/playbook/guides/create_kit/_kit_rails.html.md +2 -0
- data/app/views/playbook/guides/create_kit/_kit_react.html.md +2 -0
- data/app/views/playbook/guides/create_kit/_layout.html.md +2 -0
- data/app/views/playbook/guides/create_kit/_view_objects.html.md +2 -0
- data/app/views/playbook/guides/create_kit/_writing_sass.md +10 -0
- data/app/views/playbook/guides/use_nitro.html.slim +6 -0
- data/app/views/playbook/guides/use_nitro/_local.html.md +2 -0
- data/app/views/playbook/guides/use_nitro/_nitro_components.html.md +2 -0
- data/app/views/playbook/guides/use_nitro/_versions.html.md +2 -0
- data/app/views/playbook/pages/fullscreen.html.slim +10 -0
- data/app/views/playbook/pages/grid.html.slim +2 -0
- data/app/views/playbook/pages/home.html.slim +4 -0
- data/app/views/playbook/pages/kit_show.html.slim +14 -0
- data/app/views/playbook/pages/kits.html.slim +10 -0
- data/app/views/playbook/pages/principals/_getting_started.html.md +12 -0
- data/app/views/playbook/pages/principles.html.slim +5 -0
- data/app/views/playbook/pages/tokens.html.slim +15 -0
- data/app/views/playbook/pages/tokens/_pb_doc_spacing.html.slim +16 -0
- data/app/views/playbook/pages/utilities.html.slim +89 -0
- data/app/views/playbook/pages/utilities/_pb_doc_color.html.slim +14 -0
- data/components/Avatar/Avatar.jsx +96 -0
- data/components/Avatar/AvatarStory.jsx +19 -0
- data/components/Avatar/styles.scss +54 -0
- data/components/Avatar/styles.scss.flow +14 -0
- data/components/Badge/Badge.jsx +40 -0
- data/components/Badge/BadgeStory.jsx +40 -0
- data/components/Badge/badges.scss +167 -0
- data/components/Badge/labels.scss +121 -0
- data/components/Badge/styles.scss +4 -0
- data/components/Badge/styles.scss.flow +38 -0
- data/components/Banner/Banner.jsx +54 -0
- data/components/Banner/BannerStory.jsx +22 -0
- data/components/Banner/styles.scss +75 -0
- data/components/Banner/styles.scss.flow +19 -0
- data/components/Button/Button.jsx +75 -0
- data/components/Button/ButtonStory.jsx +94 -0
- data/components/Capping/CappingStory.jsx +21 -0
- data/components/Card/Card.jsx +44 -0
- data/components/Card/CardStory.jsx +19 -0
- data/components/CircleButton/CircleButton.jsx +51 -0
- data/components/CircleButton/CircleButtonStory.jsx +25 -0
- data/components/CircleButton/styles.scss +33 -0
- data/components/CircleButton/styles.scss.flow +6 -0
- data/components/CollapsibleCard/CollapsibleCard.jsx +108 -0
- data/components/CollapsibleCard/CollapsibleCardStory.jsx +26 -0
- data/components/Color/Color.jsx +55 -0
- data/components/Color/ColorStory.jsx +16 -0
- data/components/Color/styles.scss +6 -0
- data/components/Color/styles.scss.flow +5 -0
- data/components/ColorPickerInput/ColorPickerInput.jsx +99 -0
- data/components/ColorPickerInput/ColorPickerInputStory.jsx +37 -0
- data/components/ColorPickerInput/colorPickerInput.scss +10 -0
- data/components/ColorPickerInput/colorPickerInput.scss.flow +6 -0
- data/components/DOBInput/index.jsx +35 -0
- data/components/DOBInput/story.jsx +20 -0
- data/components/DOBInput/styles.scss +11 -0
- data/components/DOBInput/styles.scss.flow +7 -0
- data/components/DatePicker/DatePicker.jsx +156 -0
- data/components/DatePicker/DatePickerStory.jsx +22 -0
- data/components/DatePicker/styles.scss +6 -0
- data/components/DatePicker/styles.scss.flow +5 -0
- data/components/DateTimePicker/DateTimePicker.jsx +109 -0
- data/components/DateTimePicker/DateTimePickerStory.jsx +31 -0
- data/components/DateTimePicker/story-styles.scss +3 -0
- data/components/DateTimePicker/story-styles.scss.flow +5 -0
- data/components/DateTimePicker/styles.scss +1 -0
- data/components/DateTimePicker/styles.scss.flow +5 -0
- data/components/Errors/Errors.jsx +38 -0
- data/components/FileCard/FileCard.jsx +183 -0
- data/components/FileCard/FileCardStory.jsx +62 -0
- data/components/FileCard/styles.scss +81 -0
- data/components/FileCard/styles.scss.flow +12 -0
- data/components/Flip/Flip.jsx +50 -0
- data/components/Flip/FlipStory.jsx +85 -0
- data/components/Flip/styles.scss +41 -0
- data/components/Flip/styles.scss.flow +11 -0
- data/components/FlyoutPanel/FlyoutPanel.jsx +34 -0
- data/components/FlyoutPanel/FlyoutPanelStory.jsx +36 -0
- data/components/FlyoutPanel/flyout_panel.scss +33 -0
- data/components/FlyoutPanel/flyout_panel.scss.flow +11 -0
- data/components/Grade/Grade.jsx +55 -0
- data/components/Grade/GradeStory.jsx +18 -0
- data/components/Grade/grade.scss +39 -0
- data/components/Grade/grade.scss.flow +6 -0
- data/components/Highlight/Highlight.jsx +39 -0
- data/components/Highlight/HighlightStory.jsx +22 -0
- data/components/Highlight/styles.scss +24 -0
- data/components/Highlight/styles.scss.flow +17 -0
- data/components/Icon/Icon.jsx +54 -0
- data/components/Icon/IconButtonStory.jsx +20 -0
- data/components/Icon/IconStory.jsx +25 -0
- data/components/IconToggle/IconToggle.jsx +56 -0
- data/components/IconToggle/IconToggleStory.jsx +24 -0
- data/components/Milestones/MilestoneItem.jsx +47 -0
- data/components/Milestones/MilestoneItemStory.jsx +25 -0
- data/components/Milestones/Milestones.jsx +51 -0
- data/components/Milestones/MilestonesStory.jsx +30 -0
- data/components/Milestones/milestones.scss +19 -0
- data/components/Milestones/milestones.scss.flow +7 -0
- data/components/Milestones/milestones_item.scss +157 -0
- data/components/Milestones/milestones_item.scss.flow +13 -0
- data/components/Milestones/milestones_variables.scss +11 -0
- data/components/Modal/ModalStory.jsx +29 -0
- data/components/MonogramAvatar/MonogramAvatar.jsx +91 -0
- data/components/MonogramAvatar/MonogramAvatarStory.jsx +21 -0
- data/components/MonogramAvatar/monogram_avatar.scss +54 -0
- data/components/MonogramAvatar/monogram_avatar.scss.flow +10 -0
- data/components/Panel/Panel.jsx +159 -0
- data/components/Panel/PanelStory.jsx +23 -0
- data/components/Panel/panel.scss +32 -0
- data/components/Panel/panel.scss.flow +12 -0
- data/components/PanelGroup/PanelGroup.jsx +121 -0
- data/components/PanelGroup/PanelGroup.scss +96 -0
- data/components/PanelGroup/PanelGroup.scss.flow +6 -0
- data/components/PanelGroup/PanelGroupStory.jsx +112 -0
- data/components/SearchCollectionSelect/SearchCollectionSelect.jsx +29 -0
- data/components/SearchCollectionSelect/SearchCollectionSelectStory.jsx +48 -0
- data/components/SearchCollectionSelect/searchCollectionSelect.scss +0 -0
- data/components/SideModal/SideModalStory.jsx +31 -0
- data/components/Spinner/Spinner.jsx +80 -0
- data/components/Spinner/SpinnerStory.jsx +21 -0
- data/components/Spinner/spinner.scss +6 -0
- data/components/Spinner/spinner.scss.flow +5 -0
- data/components/StepMeter/StepMeter.jsx +75 -0
- data/components/StepMeter/StepMeterStory.jsx +25 -0
- data/components/StepMeter/step_meter.scss +120 -0
- data/components/StepMeter/step_meter.scss.flow +9 -0
- data/components/Survey/Survey.jsx +190 -0
- data/components/Survey/SurveyStory.jsx +125 -0
- data/components/Survey/survey.scss +75 -0
- data/components/Survey/survey.scss.flow +11 -0
- data/components/Tab/Tab.jsx +70 -0
- data/components/Tab/tab.scss +25 -0
- data/components/Tab/tab.scss.flow +6 -0
- data/components/TabList/TabList.jsx +35 -0
- data/components/TabList/TabListStory.jsx +31 -0
- data/components/TabList/tabList.scss +5 -0
- data/components/TabList/tabList.scss.flow +5 -0
- data/components/Text/Text.jsx +53 -0
- data/components/Text/TextStory.jsx +23 -0
- data/components/Text/styles.scss +3 -0
- data/components/Text/styles.scss.flow +123 -0
- data/components/Text/text.scss +35 -0
- data/components/TextInput/TextInput.jsx +95 -0
- data/components/TextInput/TextInputStory.jsx +23 -0
- data/components/TextInput/form-control.scss +96 -0
- data/components/TextInput/styles.scss +3 -0
- data/components/TextInput/styles.scss.flow +7 -0
- data/components/TimePicker/TimePicker.jsx +218 -0
- data/components/TimePicker/TimePickerStory.jsx +22 -0
- data/components/TimePicker/styles.scss +1 -0
- data/components/TimePicker/styles.scss.flow +5 -0
- data/components/ToggleButton/ToggleButton.jsx +68 -0
- data/components/ToggleButton/ToggleButtonStory.jsx +46 -0
- data/components/ToggleButton/toggleButton.scss +70 -0
- data/components/ToggleButton/toggleButton.scss.flow +14 -0
- data/components/UserStamp/UserStamp.jsx +40 -0
- data/components/UserStamp/UserStampStory.jsx +22 -0
- data/components/UserStamp/styles.scss +6 -0
- data/components/UserStamp/styles.scss.flow +7 -0
- data/components/Wip/Wip.jsx +34 -0
- data/components/index.js +33 -0
- data/components/types.js +21 -0
- data/db/migrate/20171025045845_devise_create_users.rb +42 -0
- data/db/migrate/20171025050917_create_sections.rb +9 -0
- data/db/migrate/20171025050923_create_categories.rb +10 -0
- data/db/migrate/20171025050930_create_pages.rb +12 -0
- data/db/migrate/20171025050935_create_tags.rb +9 -0
- data/db/migrate/20171025050941_create_types.rb +10 -0
- data/db/migrate/20171025051118_create_page_tags.rb +8 -0
- data/db/migrate/20171025051848_add_user_ref_to_pages.rb +5 -0
- data/db/migrate/20171025051853_add_type_ref_to_pages.rb +5 -0
- data/db/migrate/20171025051859_add_page_ref_to_page_tags.rb +5 -0
- data/db/migrate/20171025051904_add_tag_ref_to_page_tags.rb +5 -0
- data/db/migrate/20171025052205_add_section_ref_to_categories.rb +5 -0
- data/db/migrate/20171025052211_add_category_ref_to_pages.rb +5 -0
- data/db/migrate/20180327194658_add_nitro_id_to_user.rb +14 -0
- data/db/migrate/20180327195455_create_friendly_id_slugs.rb +15 -0
- data/db/migrate/20180328142634_drop_types.rb +5 -0
- data/db/migrate/20180328145054_remove_type_id_from_pages.rb +5 -0
- data/db/migrate/20180328145144_drop_friendly_id_slugs.rb +6 -0
- data/db/migrate/20180518133907_add_page_ref_to_pages.rb +5 -0
- data/db/seeds.rb +7 -0
- data/fonts/fontawesome.js +1978 -0
- data/fonts/regular.js +1217 -0
- data/lib/generators/kit/USAGE +32 -0
- data/lib/generators/kit/kit_generator.rb +86 -0
- data/lib/generators/kit/templates/html.erb +3 -0
- data/lib/generators/kit/templates/javascript.erb +4 -0
- data/lib/generators/kit/templates/jsx.erb +31 -0
- data/lib/generators/kit/templates/logo.txt +28 -0
- data/lib/generators/kit/templates/ruby.erb +48 -0
- data/lib/generators/kit/templates/scss.erb +0 -0
- data/lib/generators/kit/templates/storyrails.erb +2 -0
- data/lib/generators/kit/templates/storyreact.erb +2 -0
- data/lib/generators/kit/templates/variations.erb +10 -0
- data/lib/playbook.rb +32 -0
- data/lib/playbook/engine.rb +34 -0
- data/lib/playbook/version.rb +3 -0
- data/lib/playbook_ui.rb +3 -0
- data/lib/tasks/db.rake +8 -0
- data/lib/tasks/playbook_tasks.rake +24 -0
- data/stories/basic.js +18 -0
- data/stories/complex.js +15 -0
- data/stories/form.js +2 -0
- data/stories/index.js +29 -0
- metadata +832 -0
@@ -0,0 +1,40 @@
|
|
1
|
+
/* @flow */
|
2
|
+
|
3
|
+
import React from 'react'
|
4
|
+
import classnames from 'classnames'
|
5
|
+
|
6
|
+
import styles from './styles.scss'
|
7
|
+
|
8
|
+
type Props = {
|
9
|
+
children?: Array<React.Node>,
|
10
|
+
style: "primary" | "default" | "success" | "danger" | "warning" | "info" | "inverse",
|
11
|
+
className: string,
|
12
|
+
}
|
13
|
+
|
14
|
+
export default class Badge extends React.Component<Props> {
|
15
|
+
static defaultProps = {
|
16
|
+
children: <span>{`UR Special`}</span>,
|
17
|
+
style: "default",
|
18
|
+
className: "",
|
19
|
+
}
|
20
|
+
props: Props
|
21
|
+
render() {
|
22
|
+
const {
|
23
|
+
children,
|
24
|
+
className,
|
25
|
+
style,
|
26
|
+
} = this.props
|
27
|
+
const css = [
|
28
|
+
className,
|
29
|
+
styles.badge,
|
30
|
+
styles[`badge-${style}`],
|
31
|
+
]
|
32
|
+
return (
|
33
|
+
<span
|
34
|
+
className={classnames(css)}
|
35
|
+
>
|
36
|
+
{children}
|
37
|
+
</span>
|
38
|
+
)
|
39
|
+
}
|
40
|
+
}
|
@@ -0,0 +1,40 @@
|
|
1
|
+
import React from "react"
|
2
|
+
import Badge from "./Badge"
|
3
|
+
|
4
|
+
import { text, select } from "@storybook/addon-knobs"
|
5
|
+
|
6
|
+
export default function BadgeStory(stories) {
|
7
|
+
stories.add("Badge",
|
8
|
+
() => {
|
9
|
+
let props = {
|
10
|
+
className: text("className", ""),
|
11
|
+
style: select("style", ["primary", "default", "success", "danger", "warning", "info", "inverse"], "primary")
|
12
|
+
}
|
13
|
+
return (
|
14
|
+
<div className="row">
|
15
|
+
<div className="col-sm-1">
|
16
|
+
<Badge {...props}>Primary</Badge>
|
17
|
+
</div>
|
18
|
+
<div className="col-sm-1">
|
19
|
+
<Badge style="default">Default</Badge>
|
20
|
+
</div>
|
21
|
+
<div className="col-sm-1">
|
22
|
+
<Badge style="success">Success</Badge>
|
23
|
+
</div>
|
24
|
+
<div className="col-sm-1">
|
25
|
+
<Badge style="danger">Danger</Badge>
|
26
|
+
</div>
|
27
|
+
<div className="col-sm-1">
|
28
|
+
<Badge style="warning">Warning</Badge>
|
29
|
+
</div>
|
30
|
+
<div className="col-sm-1">
|
31
|
+
<Badge style="info">Info</Badge>
|
32
|
+
</div>
|
33
|
+
<div className="col-sm-1">
|
34
|
+
<Badge style="inverse">Inverse</Badge>
|
35
|
+
</div>
|
36
|
+
</div>
|
37
|
+
)
|
38
|
+
}
|
39
|
+
)
|
40
|
+
}
|
@@ -0,0 +1,167 @@
|
|
1
|
+
//== badges
|
2
|
+
//
|
3
|
+
//##
|
4
|
+
|
5
|
+
//** Default badge background color
|
6
|
+
$badge-default-bg: $gray-light !default;
|
7
|
+
//** Primary badge background color
|
8
|
+
$badge-primary-bg: $brand-primary !default;
|
9
|
+
//** Success badge background color
|
10
|
+
$badge-success-bg: $brand-success !default;
|
11
|
+
//** Info badge background color
|
12
|
+
$badge-info-bg: $brand-info !default;
|
13
|
+
//** Warning badge background color
|
14
|
+
$badge-warning-bg: $brand-warning !default;
|
15
|
+
//** Danger badge background color
|
16
|
+
$badge-danger-bg: $brand-danger !default;
|
17
|
+
|
18
|
+
//** Default badge text color
|
19
|
+
$badge-color: #fff !default;
|
20
|
+
//** Default text color of a linked badge
|
21
|
+
$badge-link-hover-color: #fff !default;
|
22
|
+
|
23
|
+
|
24
|
+
|
25
|
+
|
26
|
+
|
27
|
+
|
28
|
+
// badges
|
29
|
+
|
30
|
+
@mixin badge-variant($color) {
|
31
|
+
background-color: $color;
|
32
|
+
@include text-color($color, $more_contrast: true);
|
33
|
+
@if $color == $white {
|
34
|
+
border: 1px solid $border-color;
|
35
|
+
}
|
36
|
+
|
37
|
+
&[href] {
|
38
|
+
&:hover,
|
39
|
+
&:focus {
|
40
|
+
background-color: darken($color, 10%);
|
41
|
+
}
|
42
|
+
}
|
43
|
+
}
|
44
|
+
|
45
|
+
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
|
50
|
+
|
51
|
+
//
|
52
|
+
// badges
|
53
|
+
// --------------------------------------------------
|
54
|
+
|
55
|
+
|
56
|
+
|
57
|
+
.badge, .pill {
|
58
|
+
display: inline;
|
59
|
+
padding: .15em .8em;
|
60
|
+
font-size: 75%;
|
61
|
+
font-weight: $bold;
|
62
|
+
@include smooth-font;
|
63
|
+
line-height: 1;
|
64
|
+
color: $badge-color;
|
65
|
+
background: $badge-default-bg;
|
66
|
+
text-align: center;
|
67
|
+
white-space: nowrap;
|
68
|
+
vertical-align: baseline;
|
69
|
+
border-radius: .25em;
|
70
|
+
border: 1px solid transparent;
|
71
|
+
|
72
|
+
table & {
|
73
|
+
font-size: $font-smaller;
|
74
|
+
}
|
75
|
+
|
76
|
+
// [converter] extracted a& to a.badge
|
77
|
+
|
78
|
+
// Empty badges collapse automatically (not available in IE8)
|
79
|
+
&:empty {
|
80
|
+
display: none;
|
81
|
+
}
|
82
|
+
|
83
|
+
// Quick fix for badges in buttons
|
84
|
+
.btn & {
|
85
|
+
position: relative;
|
86
|
+
top: -1px;
|
87
|
+
}
|
88
|
+
// Empty badges collapse automatically (not available in IE8)
|
89
|
+
&:empty {
|
90
|
+
display: none;
|
91
|
+
}
|
92
|
+
|
93
|
+
// Quick fix for badges in buttons
|
94
|
+
.btn & {
|
95
|
+
position: relative;
|
96
|
+
top: -1px;
|
97
|
+
}
|
98
|
+
|
99
|
+
.btn-xs &,
|
100
|
+
.btn-group-xs > .btn & {
|
101
|
+
top: 0;
|
102
|
+
padding: 1px 5px;
|
103
|
+
}
|
104
|
+
|
105
|
+
// [converter] extracted a& to a.badge
|
106
|
+
|
107
|
+
// Account for badges in navs
|
108
|
+
.list-group-item.active > &,
|
109
|
+
.nav-pills > .active > a > & {
|
110
|
+
color: $white;
|
111
|
+
background-color: $black-opacity-4;
|
112
|
+
}
|
113
|
+
|
114
|
+
.list-group-item > & {
|
115
|
+
float: right;
|
116
|
+
}
|
117
|
+
|
118
|
+
.list-group-item > & + & {
|
119
|
+
margin-right: 5px;
|
120
|
+
}
|
121
|
+
|
122
|
+
.nav-pills > li > a > & {
|
123
|
+
margin-left: 3px;
|
124
|
+
}
|
125
|
+
|
126
|
+
|
127
|
+
// Colors
|
128
|
+
// Contextual variations (linked badges get darker on :hover)
|
129
|
+
|
130
|
+
&-default {
|
131
|
+
@include badge-variant($white);
|
132
|
+
}
|
133
|
+
&-primary {
|
134
|
+
@include badge-variant($power-royal);
|
135
|
+
}
|
136
|
+
&-success {
|
137
|
+
@include badge-variant($power-green);
|
138
|
+
}
|
139
|
+
&-info {
|
140
|
+
@include badge-variant($medium-teal);
|
141
|
+
}
|
142
|
+
&-warning, &-bitter {
|
143
|
+
@include badge-variant($dark-orange);
|
144
|
+
}
|
145
|
+
&-danger {
|
146
|
+
@include badge-variant($power-red);
|
147
|
+
}
|
148
|
+
&-inverse {
|
149
|
+
@include badge-variant($ink);
|
150
|
+
}
|
151
|
+
|
152
|
+
}
|
153
|
+
|
154
|
+
.pill {
|
155
|
+
border-radius: $border-rad-mega;
|
156
|
+
line-height: 1.6em;
|
157
|
+
}
|
158
|
+
|
159
|
+
// Add hover effects, but only for links
|
160
|
+
a.badge, a.pill {
|
161
|
+
&:hover,
|
162
|
+
&:focus {
|
163
|
+
color: $badge-link-hover-color;
|
164
|
+
text-decoration: none;
|
165
|
+
cursor: pointer;
|
166
|
+
}
|
167
|
+
}
|
@@ -0,0 +1,121 @@
|
|
1
|
+
//== Labels
|
2
|
+
//
|
3
|
+
//##
|
4
|
+
|
5
|
+
//** Default label background color
|
6
|
+
$label-default-bg: $gray-light !default;
|
7
|
+
//** Primary label background color
|
8
|
+
$label-primary-bg: $brand-primary !default;
|
9
|
+
//** Success label background color
|
10
|
+
$label-success-bg: $brand-success !default;
|
11
|
+
//** Info label background color
|
12
|
+
$label-info-bg: $brand-info !default;
|
13
|
+
//** Warning label background color
|
14
|
+
$label-warning-bg: $brand-warning !default;
|
15
|
+
//** Danger label background color
|
16
|
+
$label-danger-bg: $brand-danger !default;
|
17
|
+
|
18
|
+
//** Default label text color
|
19
|
+
$label-color: #fff !default;
|
20
|
+
//** Default text color of a linked label
|
21
|
+
$label-link-hover-color: #fff !default;
|
22
|
+
|
23
|
+
|
24
|
+
|
25
|
+
|
26
|
+
|
27
|
+
|
28
|
+
// Labels
|
29
|
+
|
30
|
+
@mixin label-variant($color) {
|
31
|
+
background-color: $color;
|
32
|
+
@include text-color($color);
|
33
|
+
@if $color == $white {
|
34
|
+
border: 1px solid $border-color;
|
35
|
+
}
|
36
|
+
|
37
|
+
&[href] {
|
38
|
+
&:hover,
|
39
|
+
&:focus {
|
40
|
+
background-color: darken($color, 10%);
|
41
|
+
}
|
42
|
+
}
|
43
|
+
}
|
44
|
+
|
45
|
+
|
46
|
+
|
47
|
+
|
48
|
+
|
49
|
+
|
50
|
+
|
51
|
+
//
|
52
|
+
// Labels
|
53
|
+
// --------------------------------------------------
|
54
|
+
|
55
|
+
.label {
|
56
|
+
display: inline;
|
57
|
+
padding: .15em .8em;
|
58
|
+
font-size: 75%;
|
59
|
+
font-weight: $bold;
|
60
|
+
@include smooth-font;
|
61
|
+
line-height: 1;
|
62
|
+
color: $label-color;
|
63
|
+
background: $label-default-bg;
|
64
|
+
text-align: center;
|
65
|
+
white-space: nowrap;
|
66
|
+
vertical-align: baseline;
|
67
|
+
border-radius: .25em;
|
68
|
+
|
69
|
+
table & {
|
70
|
+
@include smooth-font-off;
|
71
|
+
}
|
72
|
+
|
73
|
+
|
74
|
+
// Colors
|
75
|
+
// Contextual variations (linked badges get darker on :hover)
|
76
|
+
|
77
|
+
&-default {
|
78
|
+
@include label-variant($white);
|
79
|
+
}
|
80
|
+
&-primary {
|
81
|
+
@include label-variant($power-royal);
|
82
|
+
}
|
83
|
+
&-success {
|
84
|
+
@include label-variant($power-green);
|
85
|
+
}
|
86
|
+
&-info {
|
87
|
+
@include label-variant($medium-teal);
|
88
|
+
}
|
89
|
+
&-warning {
|
90
|
+
@include label-variant($dark-orange);
|
91
|
+
}
|
92
|
+
&-danger {
|
93
|
+
@include label-variant($power-red);
|
94
|
+
}
|
95
|
+
&-inverse {
|
96
|
+
@include label-variant($ink);
|
97
|
+
}
|
98
|
+
|
99
|
+
|
100
|
+
|
101
|
+
// Empty labels collapse automatically (not available in IE8)
|
102
|
+
&:empty {
|
103
|
+
display: none;
|
104
|
+
}
|
105
|
+
|
106
|
+
// Quick fix for labels in buttons
|
107
|
+
.btn & {
|
108
|
+
position: relative;
|
109
|
+
top: -1px;
|
110
|
+
}
|
111
|
+
}
|
112
|
+
|
113
|
+
// Add hover effects, but only for links
|
114
|
+
a.label {
|
115
|
+
&:hover,
|
116
|
+
&:focus {
|
117
|
+
color: $label-link-hover-color;
|
118
|
+
text-decoration: none;
|
119
|
+
cursor: pointer;
|
120
|
+
}
|
121
|
+
}
|
@@ -0,0 +1,38 @@
|
|
1
|
+
// @flow
|
2
|
+
/* This file is automatically generated by css-modules-flow-types */
|
3
|
+
declare module.exports: {|
|
4
|
+
+'active': string;
|
5
|
+
+'badge': string;
|
6
|
+
+'badge-bitter': string;
|
7
|
+
+'badge-danger': string;
|
8
|
+
+'badge-default': string;
|
9
|
+
+'badge-info': string;
|
10
|
+
+'badge-inverse': string;
|
11
|
+
+'badge-primary': string;
|
12
|
+
+'badge-success': string;
|
13
|
+
+'badge-warning': string;
|
14
|
+
+'btn': string;
|
15
|
+
+'btn-group-xs': string;
|
16
|
+
+'btn-xs': string;
|
17
|
+
+'hidden-xxs': string;
|
18
|
+
+'label': string;
|
19
|
+
+'label-danger': string;
|
20
|
+
+'label-default': string;
|
21
|
+
+'label-info': string;
|
22
|
+
+'label-inverse': string;
|
23
|
+
+'label-primary': string;
|
24
|
+
+'label-success': string;
|
25
|
+
+'label-warning': string;
|
26
|
+
+'list-group-item': string;
|
27
|
+
+'nav-pills': string;
|
28
|
+
+'pill': string;
|
29
|
+
+'pill-bitter': string;
|
30
|
+
+'pill-danger': string;
|
31
|
+
+'pill-default': string;
|
32
|
+
+'pill-info': string;
|
33
|
+
+'pill-inverse': string;
|
34
|
+
+'pill-primary': string;
|
35
|
+
+'pill-success': string;
|
36
|
+
+'pill-warning': string;
|
37
|
+
+'visible-xxs': string;
|
38
|
+
|};
|
@@ -0,0 +1,54 @@
|
|
1
|
+
/* @flow */
|
2
|
+
|
3
|
+
import React from "react"
|
4
|
+
import classnames from "classnames"
|
5
|
+
|
6
|
+
import styles from "./styles.scss"
|
7
|
+
|
8
|
+
export type BannerProps = {
|
9
|
+
closeable?: boolean,
|
10
|
+
children: string | React.Node | Array<React.Node>,
|
11
|
+
onClose: () => void,
|
12
|
+
position: "top" | "bottom",
|
13
|
+
show?: boolean,
|
14
|
+
style: "info" | "success" | "warning" | "danger",
|
15
|
+
}
|
16
|
+
|
17
|
+
const Banner = ({
|
18
|
+
closeable,
|
19
|
+
children,
|
20
|
+
onClose,
|
21
|
+
position,
|
22
|
+
show,
|
23
|
+
style,
|
24
|
+
}: BannerProps) => {
|
25
|
+
const css = classnames([
|
26
|
+
styles[`banner-${style}`],
|
27
|
+
styles[show ? `show-${position}` : `hide-${position}`],
|
28
|
+
])
|
29
|
+
return (
|
30
|
+
<div className={css}>
|
31
|
+
|
32
|
+
{ children }
|
33
|
+
|
34
|
+
<If condition={closeable}>
|
35
|
+
<button
|
36
|
+
className={classnames(styles.close, "close")}
|
37
|
+
onClick={onClose}
|
38
|
+
>
|
39
|
+
{`×`}
|
40
|
+
</button>
|
41
|
+
</If>
|
42
|
+
|
43
|
+
</div>
|
44
|
+
)
|
45
|
+
}
|
46
|
+
|
47
|
+
Banner.defaultProps = {
|
48
|
+
closeable: true,
|
49
|
+
position: "top",
|
50
|
+
show: false,
|
51
|
+
style: "info",
|
52
|
+
}
|
53
|
+
|
54
|
+
export default Banner
|