hakumi_components 0.1.17.pre → 0.1.18.pre
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/CHANGELOG.md +1 -1
- data/README.md +92 -70
- data/app/components/{hakumi → hakumi_components}/admin_panel/component.html.erb +2 -2
- data/app/components/{hakumi → hakumi_components}/admin_panel/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/affix/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/alert/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/alert/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/anchor/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/anchor/link/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/autocomplete/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/autocomplete/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/avatar/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/badge/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/base_component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/breadcrumb/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/breadcrumb/item/component.html.erb +2 -2
- data/app/components/{hakumi → hakumi_components}/breadcrumb/item/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/button/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/calendar/component.html.erb +5 -5
- data/app/components/{hakumi → hakumi_components}/calendar/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/card/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/card/grid/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/card/meta/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/carousel/component.html.erb +2 -2
- data/app/components/{hakumi → hakumi_components}/carousel/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/cascader/component.html.erb +2 -2
- data/app/components/{hakumi → hakumi_components}/cascader/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/checkbox/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/checkbox/group/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/checkbox/group/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/collapse/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/collapse/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/collapse/panel/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/color_picker/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/concerns/form_field.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/container/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/date_picker/component.html.erb +3 -3
- data/app/components/{hakumi → hakumi_components}/date_picker/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/date_picker/range_picker.html.erb +4 -4
- data/app/components/{hakumi → hakumi_components}/date_picker/range_picker.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/date_picker/shared_rendering.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/descriptions/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/descriptions/item/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/divider/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/drawer/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/drawer/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/dropdown/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/dropdown/divider/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/dropdown/item/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/empty/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/flex/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/float_button/back_top/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/float_button/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/float_button/group/component.rb +7 -7
- data/app/components/{hakumi → hakumi_components}/float_button/group_cluster/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/form/item/component.rb +6 -6
- data/app/components/{hakumi → hakumi_components}/grid/col/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/grid/row/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/icon/component.rb +8 -8
- data/app/components/{hakumi → hakumi_components}/image/component.html.erb +10 -10
- data/app/components/{hakumi → hakumi_components}/image/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/image/preview_group/component.html.erb +9 -9
- data/app/components/{hakumi → hakumi_components}/image/preview_group/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/input/component.rb +9 -9
- data/app/components/{hakumi → hakumi_components}/input/password/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/input/text_area/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/input_number/component.html.erb +4 -4
- data/app/components/{hakumi → hakumi_components}/input_number/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/layout/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/layout/content/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/layout/footer/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/layout/header/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/layout/sider/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/mentions/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/menu/component.rb +6 -6
- data/app/components/{hakumi → hakumi_components}/menu/divider/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/menu/group/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/menu/item/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/menu/sub_menu/component.rb +7 -7
- data/app/components/{hakumi → hakumi_components}/message/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/modal/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/modal/component.rb +2 -2
- data/app/components/hakumi_components/modal/confirm/component.html.erb +23 -0
- data/app/components/{hakumi → hakumi_components}/modal/confirm/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/modal/error/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/modal/info/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/modal/success/component.rb +5 -5
- data/app/components/{hakumi → hakumi_components}/modal/warning/component.rb +6 -6
- data/app/components/{hakumi → hakumi_components}/notification/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/pagination/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/pagination/component.rb +7 -7
- data/app/components/{hakumi → hakumi_components}/popconfirm/component.html.erb +2 -2
- data/app/components/{hakumi → hakumi_components}/popconfirm/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/popover/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/progress/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/progress/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/qr_code/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/radio/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/radio/group/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/radio/group/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/rate/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/rate/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/result/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/segmented/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/select/component.html.erb +3 -3
- data/app/components/{hakumi → hakumi_components}/select/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/skeleton/avatar/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/skeleton/button/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/skeleton/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/skeleton/image/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/skeleton/image/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/skeleton/input/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/skeleton/node/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/slider/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/space/compact/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/space/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/spin/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/splitter/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/splitter/panel/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/statistic/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/steps/component.html.erb +4 -4
- data/app/components/{hakumi → hakumi_components}/steps/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/steps/item/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/switch/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/table/column/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/table/column_group/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/table/component.rb +7 -7
- data/app/components/{hakumi → hakumi_components}/table/concerns/columns.rb +8 -8
- data/app/components/{hakumi → hakumi_components}/table/concerns/editable.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/table/concerns/ellipsis.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/table/concerns/fixed_columns.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/tabs/component.html.erb +4 -4
- data/app/components/{hakumi → hakumi_components}/tabs/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/tabs/item/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/tag/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/tag/group/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/time_picker/component.html.erb +2 -2
- data/app/components/{hakumi → hakumi_components}/time_picker/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/timeline/component.rb +4 -4
- data/app/components/{hakumi → hakumi_components}/timeline/item/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/tooltip/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/tour/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/transfer/component.html.erb +4 -4
- data/app/components/{hakumi → hakumi_components}/transfer/component.rb +2 -2
- data/app/components/{hakumi → hakumi_components}/tree/component.html.erb +1 -1
- data/app/components/{hakumi → hakumi_components}/tree/component.rb +10 -10
- data/app/components/{hakumi → hakumi_components}/tree_select/component.html.erb +5 -5
- data/app/components/{hakumi → hakumi_components}/tree_select/component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/typography/base_component.rb +3 -3
- data/app/components/{hakumi → hakumi_components}/typography/link/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/typography/paragraph/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/typography/text/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/typography/title/component.rb +1 -1
- data/app/components/{hakumi → hakumi_components}/upload/component.html.erb +10 -10
- data/app/components/{hakumi → hakumi_components}/upload/component.rb +2 -2
- data/app/controllers/{hakumi → hakumi_components}/components_controller.rb +1 -1
- data/app/form_builders/{hakumi → hakumi_components}/form_builder.rb +31 -31
- data/app/helpers/{hakumi → hakumi_components}/form_helper.rb +4 -4
- data/app/services/hakumi_components/component_handler.rb +53 -0
- data/app/services/{hakumi → hakumi_components}/icon/loader.rb +4 -4
- data/app/services/{hakumi → hakumi_components}/illustrations/loader.rb +4 -4
- data/app/views/hakumi/_admin_panel.html.erb +1 -1
- data/app/views/hakumi/_affix.html.erb +1 -1
- data/app/views/hakumi/_alert.html.erb +1 -1
- data/app/views/hakumi/_confirm.html.erb +1 -1
- data/app/views/hakumi/_drawer.html.erb +1 -1
- data/app/views/hakumi/_message.html.erb +1 -1
- data/app/views/hakumi/_modal.html.erb +1 -1
- data/app/views/hakumi/_notification.html.erb +1 -1
- data/app/views/hakumi/_popconfirm.html.erb +1 -1
- data/app/views/hakumi/_popover.html.erb +1 -1
- data/app/views/hakumi/_qr_code.html.erb +1 -1
- data/app/views/hakumi/_result.html.erb +1 -1
- data/app/views/hakumi/_segmented.html.erb +1 -1
- data/app/views/hakumi/_skeleton.html.erb +1 -1
- data/app/views/hakumi/_spin.html.erb +1 -1
- data/app/views/hakumi/_statistic.html.erb +1 -1
- data/app/views/hakumi/_table.html.erb +1 -1
- data/app/views/hakumi/_tag.html.erb +1 -1
- data/app/views/hakumi/_timeline.html.erb +1 -1
- data/app/views/hakumi/_tree.html.erb +1 -1
- data/lib/generators/{hakumi → hakumi_components}/install_generator.rb +3 -3
- data/lib/hakumi_components/documentation.rb +6 -6
- data/lib/hakumi_components/engine.rb +9 -3
- data/lib/hakumi_components/rails/attribute_introspection.rb +1 -1
- data/lib/hakumi_components/rails/validation_introspection.rb +1 -1
- data/lib/hakumi_components/rails/validation_mapper.rb +1 -1
- data/lib/hakumi_components/rails.rb +1 -1
- data/lib/hakumi_components/version.rb +2 -2
- data/lib/hakumi_components.rb +3 -2
- data/sig/generators/{hakumi → hakumi_components}/install_generator.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/admin_panel/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/affix/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/alert/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/anchor/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/anchor/link/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/autocomplete/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/avatar/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/badge/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/base_component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/breadcrumb/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/breadcrumb/item/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/button/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/calendar/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/card/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/card/grid/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/card/meta/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/carousel/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/cascader/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/checkbox/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/checkbox/group/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/collapse/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/collapse/panel/component.rbs +4 -4
- data/sig/{hakumi → hakumi_components}/color_picker/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/concerns/form_field.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/container/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/date_picker/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/date_picker/range_picker.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/date_picker/shared_rendering.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/descriptions/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/descriptions/item/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/divider/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/drawer/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/dropdown/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/dropdown/divider/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/dropdown/item/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/empty/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/flex/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/float_button/back_top/component.rbs +6 -6
- data/sig/{hakumi → hakumi_components}/float_button/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/float_button/group/component.rbs +13 -13
- data/sig/{hakumi → hakumi_components}/float_button/group_cluster/component.rbs +7 -7
- data/sig/{hakumi → hakumi_components}/form/item/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/form_builder.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/grid/col/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/grid/row/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/icon/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/image/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/image/preview_group/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/input/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/input/password/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/input/text_area/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/input_number/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/layout/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/layout/content/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/layout/footer/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/layout/header/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/layout/sider/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/mentions/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/menu/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/menu/divider/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/menu/group/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/menu/item/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/menu/sub_menu/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/message/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/modal/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/modal/confirm/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/modal/error/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/modal/info/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/modal/success/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/modal/warning/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/notification/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/pagination/component.rbs +7 -7
- data/sig/{hakumi → hakumi_components}/popconfirm/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/popover/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/progress/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/qr_code/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/radio/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/radio/group/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/rails/attribute_introspection.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/rails/validation_introspection.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/rails/validation_mapper.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/rails.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/rate/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/result/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/segmented/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/select/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/skeleton/avatar/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/skeleton/button/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/skeleton/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/skeleton/image/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/skeleton/input/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/skeleton/node/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/slider/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/space/compact/component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/space/component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/spin/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/splitter/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/splitter/panel/component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/statistic/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/steps/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/steps/item/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/switch/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/table/column/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/table/column_group/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/table/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/table/concerns/columns.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/table/concerns/editable.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/table/concerns/ellipsis.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/table/concerns/fixed_columns.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/tabs/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/tabs/item/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/tag/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/tag/group/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/time_picker/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/timeline/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/timeline/item/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/tooltip/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/tour/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/transfer/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/tree/component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/tree_select/component.rbs +3 -3
- data/sig/{hakumi → hakumi_components}/typography/base_component.rbs +2 -2
- data/sig/{hakumi → hakumi_components}/typography/link/component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/typography/paragraph/component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/typography/text/component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/typography/title/component.rbs +1 -1
- data/sig/{hakumi → hakumi_components}/upload/component.rbs +2 -2
- data/sig/{hakumi.rbs → hakumi_components.rbs} +3 -3
- metadata +340 -340
- data/app/components/hakumi/modal/confirm/component.html.erb +0 -23
- data/app/services/hakumi/component_handler.rb +0 -53
- /data/app/components/{hakumi → hakumi_components}/affix/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/anchor/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/anchor/link/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/breadcrumb/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/card/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/card/grid/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/card/meta/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/checkbox/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/color_picker/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/descriptions/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/dropdown/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/dropdown/item/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/icon/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/input/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/input/text_area/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/layout/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/layout/content/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/layout/footer/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/layout/header/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/layout/sider/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/mentions/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/menu/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/menu/group/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/menu/item/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/menu/sub_menu/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/message/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/popover/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/qr_code/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/radio/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/result/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/segmented/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/skeleton/avatar/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/skeleton/button/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/skeleton/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/skeleton/input/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/skeleton/node/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/slider/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/space/compact/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/space/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/spin/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/splitter/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/splitter/panel/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/statistic/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/steps/item/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/switch/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/table/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/timeline/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/timeline/item/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/tooltip/component.html.erb +0 -0
- /data/app/components/{hakumi → hakumi_components}/tour/component.html.erb +0 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
<%= render HakumiComponents::Modal::Component.new(
|
|
2
|
+
id: @id,
|
|
3
|
+
open: @open,
|
|
4
|
+
mask_closable: false,
|
|
5
|
+
closable: false,
|
|
6
|
+
**@html_attributes
|
|
7
|
+
) do |modal| %>
|
|
8
|
+
<% modal.with_header do %>
|
|
9
|
+
<%= @title %>
|
|
10
|
+
<% end %>
|
|
11
|
+
|
|
12
|
+
<div class="hakumi-modal-confirm-body-wrapper">
|
|
13
|
+
<%= render HakumiComponents::Icon::Component.new(name: icon_name, theme: :filled, color: icon_color, size: 22) %>
|
|
14
|
+
<div class="hakumi-modal-confirm-content">
|
|
15
|
+
<p><%= content %></p>
|
|
16
|
+
</div>
|
|
17
|
+
</div>
|
|
18
|
+
|
|
19
|
+
<% modal.with_footer do %>
|
|
20
|
+
<%= render(HakumiComponents::Button::Component.new(data: { "hakumi-action": "cancel" })) { "Cancel" } %>
|
|
21
|
+
<%= render(HakumiComponents::Button::Component.new(type: :primary, data: { "hakumi-action": "confirm" })) { "OK" } %>
|
|
22
|
+
<% end %>
|
|
23
|
+
<% end %>
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Modal
|
|
5
5
|
module Error
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
def initialize(
|
|
8
8
|
id:,
|
|
9
9
|
title: "Error",
|
|
@@ -22,7 +22,7 @@ module Hakumi
|
|
|
22
22
|
end
|
|
23
23
|
|
|
24
24
|
def call
|
|
25
|
-
render(
|
|
25
|
+
render(HakumiComponents::Modal::Component.new(
|
|
26
26
|
id: @id,
|
|
27
27
|
open: @open,
|
|
28
28
|
closable: false,
|
|
@@ -32,12 +32,12 @@ module Hakumi
|
|
|
32
32
|
modal.with_header { @title }
|
|
33
33
|
|
|
34
34
|
modal.with_footer do
|
|
35
|
-
render(
|
|
35
|
+
render(HakumiComponents::Button::Component.new(type: :primary, danger: true, data: { "hakumi-action": "close" })) { @ok_text }
|
|
36
36
|
end
|
|
37
37
|
|
|
38
38
|
content_tag(:div, class: "hakumi-modal-confirm-body-wrapper") do
|
|
39
39
|
safe_join([
|
|
40
|
-
render(
|
|
40
|
+
render(HakumiComponents::Icon::Component.new(name: :close_circle, theme: :filled, color: "#ff4d4f", size: 22)),
|
|
41
41
|
content_tag(:div, class: "hakumi-modal-confirm-content") do
|
|
42
42
|
content_tag(:p, @message || content)
|
|
43
43
|
end
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Modal
|
|
5
5
|
module Info
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
def initialize(
|
|
8
8
|
id:,
|
|
9
9
|
title: "Info",
|
|
@@ -22,7 +22,7 @@ module Hakumi
|
|
|
22
22
|
end
|
|
23
23
|
|
|
24
24
|
def call
|
|
25
|
-
render(
|
|
25
|
+
render(HakumiComponents::Modal::Component.new(
|
|
26
26
|
id: @id,
|
|
27
27
|
open: @open,
|
|
28
28
|
closable: false,
|
|
@@ -32,12 +32,12 @@ module Hakumi
|
|
|
32
32
|
modal.with_header { @title }
|
|
33
33
|
|
|
34
34
|
modal.with_footer do
|
|
35
|
-
render(
|
|
35
|
+
render(HakumiComponents::Button::Component.new(type: :primary, data: { "hakumi-action": "close" })) { @ok_text }
|
|
36
36
|
end
|
|
37
37
|
|
|
38
38
|
content_tag(:div, class: "hakumi-modal-confirm-body-wrapper") do
|
|
39
39
|
safe_join([
|
|
40
|
-
render(
|
|
40
|
+
render(HakumiComponents::Icon::Component.new(name: :info_circle, theme: :filled, color: "#1890ff", size: 22)),
|
|
41
41
|
content_tag(:div, class: "hakumi-modal-confirm-content") do
|
|
42
42
|
content_tag(:p, @message || content)
|
|
43
43
|
end
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Modal
|
|
5
5
|
module Success
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
def initialize(
|
|
8
8
|
id:,
|
|
9
9
|
title: "Success",
|
|
@@ -22,7 +22,7 @@ module Hakumi
|
|
|
22
22
|
end
|
|
23
23
|
|
|
24
24
|
def call
|
|
25
|
-
render(
|
|
25
|
+
render(HakumiComponents::Modal::Component.new(
|
|
26
26
|
id: @id,
|
|
27
27
|
open: @open,
|
|
28
28
|
closable: false,
|
|
@@ -32,12 +32,12 @@ module Hakumi
|
|
|
32
32
|
modal.with_header { @title }
|
|
33
33
|
|
|
34
34
|
modal.with_footer do
|
|
35
|
-
render(
|
|
35
|
+
render(HakumiComponents::Button::Component.new(type: :primary, data: { "hakumi-action": "close" })) { @ok_text }
|
|
36
36
|
end
|
|
37
37
|
|
|
38
38
|
content_tag(:div, class: "hakumi-modal-confirm-body-wrapper") do
|
|
39
39
|
safe_join([
|
|
40
|
-
render(
|
|
40
|
+
render(HakumiComponents::Icon::Component.new(name: :check_circle, theme: :filled, color: "#52c41a", size: 22)),
|
|
41
41
|
content_tag(:div, class: "hakumi-modal-confirm-content") do
|
|
42
42
|
content_tag(:p, @message || content)
|
|
43
43
|
end
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Modal
|
|
5
5
|
module Warning
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
def initialize(
|
|
8
8
|
id:,
|
|
9
9
|
title: "Warning",
|
|
@@ -24,7 +24,7 @@ module Hakumi
|
|
|
24
24
|
end
|
|
25
25
|
|
|
26
26
|
def call
|
|
27
|
-
render(
|
|
27
|
+
render(HakumiComponents::Modal::Component.new(
|
|
28
28
|
id: @id,
|
|
29
29
|
open: @open,
|
|
30
30
|
closable: false,
|
|
@@ -35,14 +35,14 @@ module Hakumi
|
|
|
35
35
|
|
|
36
36
|
modal.with_footer do
|
|
37
37
|
safe_join([
|
|
38
|
-
render(
|
|
39
|
-
render(
|
|
38
|
+
render(HakumiComponents::Button::Component.new(data: { "hakumi-action": "cancel" })) { @cancel_text },
|
|
39
|
+
render(HakumiComponents::Button::Component.new(type: :primary, data: { "hakumi-action": "confirm" })) { @ok_text }
|
|
40
40
|
])
|
|
41
41
|
end
|
|
42
42
|
|
|
43
43
|
content_tag(:div, class: "hakumi-modal-confirm-body-wrapper") do
|
|
44
44
|
safe_join([
|
|
45
|
-
render(
|
|
45
|
+
render(HakumiComponents::Icon::Component.new(name: :warning, theme: :filled, color: "#faad14", size: 22)),
|
|
46
46
|
content_tag(:div, class: "hakumi-modal-confirm-content") do
|
|
47
47
|
content_tag(:p, @message || content)
|
|
48
48
|
end
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Notification
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
TYPES = %i[success info warning error].freeze
|
|
7
7
|
PLACEMENTS = %w[top topLeft topRight bottom bottomLeft bottomRight].freeze
|
|
8
8
|
|
|
@@ -87,7 +87,7 @@
|
|
|
87
87
|
<% if show_size_changer? && !simple %>
|
|
88
88
|
<li class="hakumi-pagination-options">
|
|
89
89
|
<div class="hakumi-pagination-options-size-changer" data-hakumi--pagination-target="sizeChanger">
|
|
90
|
-
<%= render
|
|
90
|
+
<%= render HakumiComponents::Select::Component.new(
|
|
91
91
|
options: page_size_options.map { |size| ["#{size} / page", size] },
|
|
92
92
|
value: page_size,
|
|
93
93
|
size: :middle,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Pagination
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
SIZES = %i[default small].freeze
|
|
7
7
|
ALIGNS = %i[start center end].freeze
|
|
8
8
|
DEFAULT_PAGE_SIZE_OPTIONS = [ 10, 20, 50, 100 ].freeze
|
|
@@ -158,23 +158,23 @@ module Hakumi
|
|
|
158
158
|
end
|
|
159
159
|
|
|
160
160
|
def prev_icon
|
|
161
|
-
|
|
161
|
+
HakumiComponents::Icon::Component.new(name: :left)
|
|
162
162
|
end
|
|
163
163
|
|
|
164
164
|
def next_icon
|
|
165
|
-
|
|
165
|
+
HakumiComponents::Icon::Component.new(name: :right)
|
|
166
166
|
end
|
|
167
167
|
|
|
168
168
|
def jump_prev_icon
|
|
169
|
-
|
|
169
|
+
HakumiComponents::Icon::Component.new(name: :double_left)
|
|
170
170
|
end
|
|
171
171
|
|
|
172
172
|
def jump_next_icon
|
|
173
|
-
|
|
173
|
+
HakumiComponents::Icon::Component.new(name: :double_right)
|
|
174
174
|
end
|
|
175
175
|
|
|
176
176
|
def ellipsis_icon
|
|
177
|
-
|
|
177
|
+
HakumiComponents::Icon::Component.new(name: :ellipsis)
|
|
178
178
|
end
|
|
179
179
|
|
|
180
180
|
def total_text
|
|
@@ -35,13 +35,13 @@
|
|
|
35
35
|
<%= buttons %>
|
|
36
36
|
<% else %>
|
|
37
37
|
<% if @show_cancel %>
|
|
38
|
-
<%= render(
|
|
38
|
+
<%= render(HakumiComponents::Button::Component.new(
|
|
39
39
|
size: :small,
|
|
40
40
|
data: { "hakumi-action": "cancel" }
|
|
41
41
|
)) { "Cancel" } %>
|
|
42
42
|
<% end %>
|
|
43
43
|
|
|
44
|
-
<%= render(
|
|
44
|
+
<%= render(HakumiComponents::Button::Component.new(
|
|
45
45
|
type: @ok_type,
|
|
46
46
|
size: :small,
|
|
47
47
|
data: { "hakumi-action": "confirm" }
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Popconfirm
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
PLACEMENTS = %w[
|
|
7
7
|
top topLeft topRight
|
|
8
8
|
bottom bottomLeft bottomRight
|
|
@@ -65,7 +65,7 @@ module Hakumi
|
|
|
65
65
|
end
|
|
66
66
|
|
|
67
67
|
def default_icon_element
|
|
68
|
-
render
|
|
68
|
+
render HakumiComponents::Icon::Component.new(name: "exclamation-circle", theme: :filled)
|
|
69
69
|
end
|
|
70
70
|
end
|
|
71
71
|
end
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
<% end %>
|
|
74
74
|
|
|
75
75
|
<% if wrap_with_tooltip? %>
|
|
76
|
-
<%= render
|
|
76
|
+
<%= render HakumiComponents::Tooltip::Component.new(**tooltip_component_options) do %>
|
|
77
77
|
<%= component_markup %>
|
|
78
78
|
<% end %>
|
|
79
79
|
<% else %>
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Progress
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
TYPES = [ :line, :circle, :dashboard ].freeze
|
|
7
7
|
STATUSES = [ :normal, :success, :exception, :active ].freeze
|
|
8
8
|
LINE_SIZES = [ :small, :default ].freeze
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module QrCode
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
TYPES = [ :canvas, :svg ].freeze
|
|
7
7
|
STATUSES = [ :active, :expired, :loading, :scanned ].freeze
|
|
8
8
|
ERROR_LEVELS = [ :L, :M, :Q, :H ].freeze
|
|
@@ -232,7 +232,7 @@ module Hakumi
|
|
|
232
232
|
icon_name = extract_icon_name(@icon_input)
|
|
233
233
|
return unless icon_name
|
|
234
234
|
|
|
235
|
-
@icon_component =
|
|
235
|
+
@icon_component = HakumiComponents::Icon::Component.new(name: icon_name, size: icon_component_size)
|
|
236
236
|
end
|
|
237
237
|
|
|
238
238
|
def icon_component?
|
|
@@ -282,7 +282,7 @@ module Hakumi
|
|
|
282
282
|
def default_status_overlay
|
|
283
283
|
content = []
|
|
284
284
|
if loading?
|
|
285
|
-
content << render(
|
|
285
|
+
content << render(HakumiComponents::Spin::Component.new(size: :small))
|
|
286
286
|
end
|
|
287
287
|
|
|
288
288
|
content << tag.span(status_text, class: "hakumi-qr-code-status-text")
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Radio
|
|
5
|
-
class Component <
|
|
6
|
-
include
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
|
+
include HakumiComponents::Concerns::FormField
|
|
7
7
|
|
|
8
8
|
SIZES = [ :small, :middle, :large ].freeze
|
|
9
9
|
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
<span class="hakumi-radio-button-label"><%= option[:label] %></span>
|
|
19
19
|
</label>
|
|
20
20
|
<% else %>
|
|
21
|
-
<%= render
|
|
21
|
+
<%= render HakumiComponents::Radio::Component.new(
|
|
22
22
|
name: @name,
|
|
23
23
|
value: option[:value],
|
|
24
24
|
checked: option_checked?(option[:value]),
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Radio
|
|
5
5
|
module Group
|
|
6
|
-
class Component <
|
|
7
|
-
include
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
|
+
include HakumiComponents::Concerns::FormField
|
|
8
8
|
|
|
9
9
|
SIZES = [ :small, :middle, :large ].freeze
|
|
10
10
|
VARIANTS = [ :default, :button, :solid ].freeze
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
<span class="hakumi-rate-star-second"><%= character_content %></span>
|
|
19
19
|
<% end %>
|
|
20
20
|
<% if tooltip_text.present? %>
|
|
21
|
-
<%= render
|
|
21
|
+
<%= render HakumiComponents::Tooltip::Component.new(title: tooltip_text) do %>
|
|
22
22
|
<%= star_element %>
|
|
23
23
|
<% end %>
|
|
24
24
|
<% else %>
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Rate
|
|
5
5
|
# Hakumi Rate component
|
|
6
6
|
# Supports half selection, clearing, and form integration.
|
|
7
|
-
class Component <
|
|
8
|
-
include
|
|
7
|
+
class Component < HakumiComponents::BaseComponent
|
|
8
|
+
include HakumiComponents::Concerns::FormField
|
|
9
9
|
|
|
10
10
|
def initialize(
|
|
11
11
|
name: nil,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Result
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
STATUSES = %w[success info warning error].freeze
|
|
7
7
|
|
|
8
8
|
DEFAULT_TITLES = {
|
|
@@ -109,7 +109,7 @@ module Hakumi
|
|
|
109
109
|
config = STATUS_ICON_MAP[@status]
|
|
110
110
|
return unless config
|
|
111
111
|
|
|
112
|
-
|
|
112
|
+
HakumiComponents::Icon::Component.new(
|
|
113
113
|
name: config[:name],
|
|
114
114
|
theme: config[:theme],
|
|
115
115
|
size: STATUS_ICON_SIZE,
|
|
@@ -118,7 +118,7 @@ module Hakumi
|
|
|
118
118
|
end
|
|
119
119
|
|
|
120
120
|
def default_icon
|
|
121
|
-
|
|
121
|
+
HakumiComponents::Illustrations::Loader.load(DEFAULT_ICON_NAME)
|
|
122
122
|
end
|
|
123
123
|
end
|
|
124
124
|
end
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Segmented
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
SIZES = [ :small, :middle, :large ].freeze
|
|
7
7
|
|
|
8
8
|
def self.extract_controller_locals(params)
|
|
@@ -137,7 +137,7 @@ module Hakumi
|
|
|
137
137
|
return nil if icon.nil?
|
|
138
138
|
|
|
139
139
|
if icon.is_a?(String) || icon.is_a?(Symbol)
|
|
140
|
-
render
|
|
140
|
+
render HakumiComponents::Icon::Component.new(name: icon, color: "currentColor")
|
|
141
141
|
elsif icon.respond_to?(:render_in)
|
|
142
142
|
render(icon)
|
|
143
143
|
else
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<% if borderless? %>
|
|
13
13
|
<div class="hakumi-select-selector" <%= "data-action=click->hakumi--select#toggle" unless hover_trigger? %>>
|
|
14
14
|
<span class="hakumi-select-selection-item" data-hakumi--select-target="label" style="display: none;"></span>
|
|
15
|
-
<%= render
|
|
15
|
+
<%= render HakumiComponents::Icon::Component.new(name: icon || :ellipsis) %>
|
|
16
16
|
</div>
|
|
17
17
|
<% else %>
|
|
18
18
|
<div class="hakumi-select-selector" data-action="click->hakumi--select#toggle">
|
|
@@ -54,12 +54,12 @@
|
|
|
54
54
|
data-action="click->hakumi--select#clear"
|
|
55
55
|
style="<%= @value.present? ? '' : 'display: none;' %>"
|
|
56
56
|
data-hakumi--select-target="clearBtn">
|
|
57
|
-
<%= render
|
|
57
|
+
<%= render HakumiComponents::Icon::Component.new(name: :close_circle, theme: :filled) %>
|
|
58
58
|
</span>
|
|
59
59
|
<% end %>
|
|
60
60
|
|
|
61
61
|
<span class="hakumi-select-arrow">
|
|
62
|
-
<%= render
|
|
62
|
+
<%= render HakumiComponents::Icon::Component.new(name: :down) %>
|
|
63
63
|
</span>
|
|
64
64
|
<% end %>
|
|
65
65
|
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Select
|
|
5
5
|
# Hakumi Select component
|
|
6
6
|
# A custom selector component that mimics Ant Design React behavior
|
|
7
|
-
class Component <
|
|
8
|
-
include
|
|
7
|
+
class Component < HakumiComponents::BaseComponent
|
|
8
|
+
include HakumiComponents::Concerns::FormField
|
|
9
9
|
|
|
10
10
|
SIZES = [ :small, :middle, :large ].freeze
|
|
11
11
|
VARIANTS = [ :default, :borderless ].freeze
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Skeleton
|
|
5
5
|
module Avatar
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
SIZES = [ :small, :default, :large ].freeze
|
|
8
8
|
SHAPES = [ :circle, :square ].freeze
|
|
9
9
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Skeleton
|
|
5
5
|
module Button
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
SIZES = [ :small, :default, :large ].freeze
|
|
8
8
|
SHAPES = [ :default, :circle, :round ].freeze
|
|
9
9
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Skeleton
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
AVATAR_SIZES = [ :small, :default, :large ].freeze
|
|
7
7
|
AVATAR_SHAPES = [ :circle, :square ].freeze
|
|
8
8
|
DEFAULT_PARAGRAPH_ROWS = 3
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<%= tag.span(**wrapper_attributes) do %>
|
|
2
2
|
<%= tag.span(class: image_classes, style: image_style) do %>
|
|
3
|
-
<%= render(
|
|
3
|
+
<%= render(HakumiComponents::Icon::Component.new(**icon_component_options)) %>
|
|
4
4
|
<% end %>
|
|
5
5
|
<% end %>
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Skeleton
|
|
5
5
|
module Image
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
DEFAULT_ICON_NAME = "picture"
|
|
8
8
|
DEFAULT_ICON_THEME = :outlined
|
|
9
9
|
DEFAULT_ICON_SIZE = 48
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Skeleton
|
|
5
5
|
module Input
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
SIZES = [ :small, :default, :large ].freeze
|
|
8
8
|
|
|
9
9
|
def initialize(active: false, size: :default, block: false, **html_options)
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Skeleton
|
|
5
5
|
module Node
|
|
6
|
-
class Component <
|
|
6
|
+
class Component < HakumiComponents::BaseComponent
|
|
7
7
|
def initialize(active: false, size: 40, **html_options)
|
|
8
8
|
@active = active
|
|
9
9
|
@size = size
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Slider
|
|
5
5
|
# Hakumi Slider component
|
|
6
6
|
# Supports single and range sliders with marks, dots, and vertical layout.
|
|
7
|
-
class Component <
|
|
8
|
-
include
|
|
7
|
+
class Component < HakumiComponents::BaseComponent
|
|
8
|
+
include HakumiComponents::Concerns::FormField
|
|
9
9
|
|
|
10
10
|
def initialize(
|
|
11
11
|
name: nil,
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
module
|
|
3
|
+
module HakumiComponents
|
|
4
4
|
module Spin
|
|
5
|
-
class Component <
|
|
5
|
+
class Component < HakumiComponents::BaseComponent
|
|
6
6
|
SIZES = [ :small, :default, :large ].freeze
|
|
7
7
|
|
|
8
8
|
def self.extract_controller_locals(params)
|
|
@@ -97,7 +97,7 @@ module Hakumi
|
|
|
97
97
|
end
|
|
98
98
|
|
|
99
99
|
def progress_component
|
|
100
|
-
|
|
100
|
+
HakumiComponents::Progress::Component.new(
|
|
101
101
|
percent: @percent,
|
|
102
102
|
type: :circle,
|
|
103
103
|
size: progress_size,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
module
|
|
1
|
+
module HakumiComponents
|
|
2
2
|
module Splitter
|
|
3
|
-
class Component <
|
|
3
|
+
class Component < HakumiComponents::BaseComponent
|
|
4
4
|
def initialize(layout: :horizontal, resizable: true, **html_options)
|
|
5
5
|
@layout = layout
|
|
6
6
|
@resizable = resizable
|