maxit-cli 0.1.0
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.
- package/LICENSE +49 -0
- package/README.md +56 -0
- package/bin/maxit.js +75 -0
- package/lib/commands.js +142 -0
- package/lib/project.js +58 -0
- package/lib/registry.js +50 -0
- package/package.json +30 -0
- package/registry/components/action-sheet/action-sheet.js +1 -0
- package/registry/components/action-sheet/action-sheet.json +1 -0
- package/registry/components/action-sheet/action-sheet.wxml +1 -0
- package/registry/components/action-sheet/action-sheet.wxs +34 -0
- package/registry/components/action-sheet/action-sheet.wxss +197 -0
- package/registry/components/action-sheet/index.js +1 -0
- package/registry/components/action-sheet/props.js +1 -0
- package/registry/components/action-sheet/show.js +1 -0
- package/registry/components/action-sheet/template/grid.wxml +1 -0
- package/registry/components/avatar/avatar.js +1 -0
- package/registry/components/avatar/avatar.json +1 -0
- package/registry/components/avatar/avatar.wxml +1 -0
- package/registry/components/avatar/avatar.wxs +30 -0
- package/registry/components/avatar/avatar.wxss +105 -0
- package/registry/components/avatar/index.js +1 -0
- package/registry/components/avatar/props.js +1 -0
- package/registry/components/avatar-group/avatar-group.js +1 -0
- package/registry/components/avatar-group/avatar-group.json +1 -0
- package/registry/components/avatar-group/avatar-group.wxml +1 -0
- package/registry/components/avatar-group/avatar-group.wxss +248 -0
- package/registry/components/avatar-group/index.js +1 -0
- package/registry/components/avatar-group/props.js +1 -0
- package/registry/components/back-top/back-top.js +1 -0
- package/registry/components/back-top/back-top.json +1 -0
- package/registry/components/back-top/back-top.wxml +1 -0
- package/registry/components/back-top/back-top.wxss +77 -0
- package/registry/components/back-top/index.js +1 -0
- package/registry/components/back-top/props.js +1 -0
- package/registry/components/badge/badge.js +1 -0
- package/registry/components/badge/badge.json +1 -0
- package/registry/components/badge/badge.wxml +1 -0
- package/registry/components/badge/badge.wxs +64 -0
- package/registry/components/badge/badge.wxss +168 -0
- package/registry/components/badge/index.js +1 -0
- package/registry/components/badge/props.js +1 -0
- package/registry/components/balance-card/balance-card.js +34 -0
- package/registry/components/balance-card/balance-card.json +1 -0
- package/registry/components/balance-card/balance-card.wxml +33 -0
- package/registry/components/balance-card/balance-card.wxss +111 -0
- package/registry/components/balance-card/index.js +2 -0
- package/registry/components/balance-card/props.js +14 -0
- package/registry/components/balance-thumb-card/balance-thumb-card.js +39 -0
- package/registry/components/balance-thumb-card/balance-thumb-card.json +1 -0
- package/registry/components/balance-thumb-card/balance-thumb-card.wxml +26 -0
- package/registry/components/balance-thumb-card/balance-thumb-card.wxss +31 -0
- package/registry/components/balance-thumb-card/index.js +2 -0
- package/registry/components/balance-thumb-card/props.js +17 -0
- package/registry/components/bill-card/bill-card.js +23 -0
- package/registry/components/bill-card/bill-card.json +1 -0
- package/registry/components/bill-card/bill-card.wxml +30 -0
- package/registry/components/bill-card/bill-card.wxss +33 -0
- package/registry/components/bill-card/index.js +2 -0
- package/registry/components/bill-card/props.js +18 -0
- package/registry/components/button/button.js +1 -0
- package/registry/components/button/button.json +1 -0
- package/registry/components/button/button.wxml +1 -0
- package/registry/components/button/button.wxss +775 -0
- package/registry/components/button/index.js +1 -0
- package/registry/components/button/props.js +1 -0
- package/registry/components/calendar/calendar-header.wxml +1 -0
- package/registry/components/calendar/calendar.js +1 -0
- package/registry/components/calendar/calendar.json +1 -0
- package/registry/components/calendar/calendar.wxml +1 -0
- package/registry/components/calendar/calendar.wxs +44 -0
- package/registry/components/calendar/calendar.wxss +246 -0
- package/registry/components/calendar/index.js +1 -0
- package/registry/components/calendar/props.js +1 -0
- package/registry/components/calendar/template.wxml +1 -0
- package/registry/components/calendar/utils.js +1 -0
- package/registry/components/card/card.js +24 -0
- package/registry/components/card/card.json +1 -0
- package/registry/components/card/card.wxml +23 -0
- package/registry/components/card/card.wxss +103 -0
- package/registry/components/card/index.js +2 -0
- package/registry/components/card/props.js +16 -0
- package/registry/components/card-list/card-list.js +22 -0
- package/registry/components/card-list/card-list.json +1 -0
- package/registry/components/card-list/card-list.wxml +7 -0
- package/registry/components/card-list/card-list.wxss +30 -0
- package/registry/components/card-list/index.js +2 -0
- package/registry/components/card-list/props.js +16 -0
- package/registry/components/cascader/cascader.js +1 -0
- package/registry/components/cascader/cascader.json +1 -0
- package/registry/components/cascader/cascader.wxml +1 -0
- package/registry/components/cascader/cascader.wxss +178 -0
- package/registry/components/cascader/index.js +1 -0
- package/registry/components/cascader/props.js +1 -0
- package/registry/components/category-filter/category-filter.js +50 -0
- package/registry/components/category-filter/category-filter.json +1 -0
- package/registry/components/category-filter/category-filter.wxml +16 -0
- package/registry/components/category-filter/category-filter.wxss +47 -0
- package/registry/components/category-filter/index.js +2 -0
- package/registry/components/category-filter/props.js +10 -0
- package/registry/components/cell/cell.js +1 -0
- package/registry/components/cell/cell.json +1 -0
- package/registry/components/cell/cell.wxml +1 -0
- package/registry/components/cell/cell.wxss +136 -0
- package/registry/components/cell/index.js +1 -0
- package/registry/components/cell/props.js +1 -0
- package/registry/components/check-tag/check-tag.js +1 -0
- package/registry/components/check-tag/check-tag.json +1 -0
- package/registry/components/check-tag/check-tag.wxml +1 -0
- package/registry/components/check-tag/check-tag.wxss +275 -0
- package/registry/components/check-tag/index.js +1 -0
- package/registry/components/check-tag/props.js +1 -0
- package/registry/components/checkbox/checkbox.js +1 -0
- package/registry/components/checkbox/checkbox.json +1 -0
- package/registry/components/checkbox/checkbox.wxml +1 -0
- package/registry/components/checkbox/checkbox.wxss +230 -0
- package/registry/components/checkbox/index.js +1 -0
- package/registry/components/checkbox/props.js +1 -0
- package/registry/components/checkbox-group/checkbox-group.js +1 -0
- package/registry/components/checkbox-group/checkbox-group.json +1 -0
- package/registry/components/checkbox-group/checkbox-group.wxml +1 -0
- package/registry/components/checkbox-group/checkbox-group.wxss +7 -0
- package/registry/components/checkbox-group/index.js +1 -0
- package/registry/components/checkbox-group/props.js +1 -0
- package/registry/components/collapse/collapse.js +1 -0
- package/registry/components/collapse/collapse.json +1 -0
- package/registry/components/collapse/collapse.wxml +1 -0
- package/registry/components/collapse/collapse.wxss +8 -0
- package/registry/components/collapse/index.js +1 -0
- package/registry/components/collapse/props.js +1 -0
- package/registry/components/collapse-panel/collapse-panel.js +1 -0
- package/registry/components/collapse-panel/collapse-panel.json +1 -0
- package/registry/components/collapse-panel/collapse-panel.wxml +1 -0
- package/registry/components/collapse-panel/collapse-panel.wxss +186 -0
- package/registry/components/collapse-panel/index.js +1 -0
- package/registry/components/collapse-panel/props.js +1 -0
- package/registry/components/color-picker/color-picker.js +1 -0
- package/registry/components/color-picker/color-picker.json +1 -0
- package/registry/components/color-picker/color-picker.wxml +1 -0
- package/registry/components/color-picker/color-picker.wxss +312 -0
- package/registry/components/color-picker/constants.js +1 -0
- package/registry/components/color-picker/index.js +1 -0
- package/registry/components/color-picker/interfaces.js +1 -0
- package/registry/components/color-picker/props.js +1 -0
- package/registry/components/color-picker/template.wxml +1 -0
- package/registry/components/color-picker/utils.js +1 -0
- package/registry/components/common/bus.js +1 -0
- package/registry/components/common/config.js +1 -0
- package/registry/components/common/libs/tinycolor.js +1 -0
- package/registry/components/common/locale.js +20 -0
- package/registry/components/common/mixins/page-scroll.js +1 -0
- package/registry/components/common/mixins/touch.js +1 -0
- package/registry/components/common/mixins/transition.js +1 -0
- package/registry/components/common/mixins/using-config.js +24 -0
- package/registry/components/common/mixins/using-custom-navbar.js +1 -0
- package/registry/components/common/shared/calendar/index.js +1 -0
- package/registry/components/common/shared/color-picker/cmyk.js +1 -0
- package/registry/components/common/shared/color-picker/color.js +1 -0
- package/registry/components/common/shared/color-picker/gradient.js +1 -0
- package/registry/components/common/shared/color-picker/index.js +1 -0
- package/registry/components/common/shared/date.js +1 -0
- package/registry/components/common/shared/qrcode/qrcodegen.js +1 -0
- package/registry/components/common/shared/qrcode/utils.js +1 -0
- package/registry/components/common/src/control.js +1 -0
- package/registry/components/common/src/flatTool.js +1 -0
- package/registry/components/common/src/index.js +1 -0
- package/registry/components/common/src/instantiationDecorator.js +1 -0
- package/registry/components/common/src/superComponent.js +1 -0
- package/registry/components/common/style/card.wxss +245 -0
- package/registry/components/common/style/index.wxss +3 -0
- package/registry/components/common/style/tokens.wxss +233 -0
- package/registry/components/common/template/badge.wxml +1 -0
- package/registry/components/common/template/button.wxml +1 -0
- package/registry/components/common/template/icon.wxml +1 -0
- package/registry/components/common/template/image.wxml +1 -0
- package/registry/components/common/tslib.js +2 -0
- package/registry/components/common/typography/ellipsis.wxml +1 -0
- package/registry/components/common/typography/typography.wxs +49 -0
- package/registry/components/common/utils.js +1 -0
- package/registry/components/common/utils.wxs +149 -0
- package/registry/components/common/validator.js +1 -0
- package/registry/components/common/wechat.js +1 -0
- package/registry/components/consumption-card/consumption-card.js +23 -0
- package/registry/components/consumption-card/consumption-card.json +1 -0
- package/registry/components/consumption-card/consumption-card.wxml +16 -0
- package/registry/components/consumption-card/consumption-card.wxss +36 -0
- package/registry/components/consumption-card/index.js +2 -0
- package/registry/components/consumption-card/props.js +14 -0
- package/registry/components/contact-list/contact-list.js +60 -0
- package/registry/components/contact-list/contact-list.json +1 -0
- package/registry/components/contact-list/contact-list.wxml +24 -0
- package/registry/components/contact-list/contact-list.wxss +73 -0
- package/registry/components/contact-list/index.js +2 -0
- package/registry/components/contact-list/props.js +13 -0
- package/registry/components/description-tile/description-tile.js +22 -0
- package/registry/components/description-tile/description-tile.json +1 -0
- package/registry/components/description-tile/description-tile.wxml +11 -0
- package/registry/components/description-tile/description-tile.wxss +21 -0
- package/registry/components/description-tile/index.js +2 -0
- package/registry/components/description-tile/props.js +10 -0
- package/registry/components/details-card/details-card.js +38 -0
- package/registry/components/details-card/details-card.json +1 -0
- package/registry/components/details-card/details-card.wxml +37 -0
- package/registry/components/details-card/details-card.wxss +119 -0
- package/registry/components/details-card/index.js +2 -0
- package/registry/components/details-card/props.js +22 -0
- package/registry/components/dialog/dialog.js +1 -0
- package/registry/components/dialog/dialog.json +1 -0
- package/registry/components/dialog/dialog.wxml +1 -0
- package/registry/components/dialog/dialog.wxs +13 -0
- package/registry/components/dialog/dialog.wxss +123 -0
- package/registry/components/dialog/index.js +1 -0
- package/registry/components/dialog/props.js +1 -0
- package/registry/components/divider/divider.js +1 -0
- package/registry/components/divider/divider.json +1 -0
- package/registry/components/divider/divider.wxml +1 -0
- package/registry/components/divider/divider.wxss +69 -0
- package/registry/components/divider/index.js +1 -0
- package/registry/components/divider/props.js +1 -0
- package/registry/components/drawer/drawer.js +1 -0
- package/registry/components/drawer/drawer.json +1 -0
- package/registry/components/drawer/drawer.wxml +1 -0
- package/registry/components/drawer/drawer.wxss +75 -0
- package/registry/components/drawer/index.js +1 -0
- package/registry/components/drawer/props.js +1 -0
- package/registry/components/dropdown-item/dropdown-item.js +1 -0
- package/registry/components/dropdown-item/dropdown-item.json +1 -0
- package/registry/components/dropdown-item/dropdown-item.wxml +1 -0
- package/registry/components/dropdown-item/dropdown-item.wxss +116 -0
- package/registry/components/dropdown-item/index.js +1 -0
- package/registry/components/dropdown-item/index.wxs +9 -0
- package/registry/components/dropdown-item/props.js +1 -0
- package/registry/components/dropdown-menu/dropdown-menu.js +1 -0
- package/registry/components/dropdown-menu/dropdown-menu.json +1 -0
- package/registry/components/dropdown-menu/dropdown-menu.wxml +1 -0
- package/registry/components/dropdown-menu/dropdown-menu.wxss +72 -0
- package/registry/components/dropdown-menu/index.js +1 -0
- package/registry/components/dropdown-menu/props.js +1 -0
- package/registry/components/empty/empty.js +1 -0
- package/registry/components/empty/empty.json +1 -0
- package/registry/components/empty/empty.wxml +1 -0
- package/registry/components/empty/empty.wxss +28 -0
- package/registry/components/empty/index.js +1 -0
- package/registry/components/empty/props.js +1 -0
- package/registry/components/entry-card/entry-card.js +23 -0
- package/registry/components/entry-card/entry-card.json +1 -0
- package/registry/components/entry-card/entry-card.wxml +14 -0
- package/registry/components/entry-card/entry-card.wxss +30 -0
- package/registry/components/entry-card/index.js +2 -0
- package/registry/components/entry-card/props.js +11 -0
- package/registry/components/file-drop/file-drop.js +23 -0
- package/registry/components/file-drop/file-drop.json +1 -0
- package/registry/components/file-drop/file-drop.wxml +13 -0
- package/registry/components/file-drop/file-drop.wxss +35 -0
- package/registry/components/file-drop/index.js +2 -0
- package/registry/components/file-drop/props.js +9 -0
- package/registry/components/grid/grid.js +1 -0
- package/registry/components/grid/grid.json +1 -0
- package/registry/components/grid/grid.wxml +1 -0
- package/registry/components/grid/grid.wxss +18 -0
- package/registry/components/grid/index.js +1 -0
- package/registry/components/grid/props.js +1 -0
- package/registry/components/grid-item/grid-item.js +1 -0
- package/registry/components/grid-item/grid-item.json +1 -0
- package/registry/components/grid-item/grid-item.wxml +1 -0
- package/registry/components/grid-item/grid-item.wxss +130 -0
- package/registry/components/grid-item/index.js +1 -0
- package/registry/components/grid-item/props.js +1 -0
- package/registry/components/guide/content.wxml +1 -0
- package/registry/components/guide/guide.js +1 -0
- package/registry/components/guide/guide.json +1 -0
- package/registry/components/guide/guide.wxml +1 -0
- package/registry/components/guide/guide.wxss +79 -0
- package/registry/components/guide/index.js +1 -0
- package/registry/components/guide/props.js +1 -0
- package/registry/components/icon/icon.js +1 -0
- package/registry/components/icon/icon.json +1 -0
- package/registry/components/icon/icon.wxml +1 -0
- package/registry/components/icon/icon.wxss +2361 -0
- package/registry/components/icon/index.js +1 -0
- package/registry/components/icon/props.js +1 -0
- package/registry/components/image/image.js +1 -0
- package/registry/components/image/image.json +1 -0
- package/registry/components/image/image.wxml +1 -0
- package/registry/components/image/image.wxss +55 -0
- package/registry/components/image/index.js +1 -0
- package/registry/components/image/props.js +1 -0
- package/registry/components/image-viewer/image-viewer.js +1 -0
- package/registry/components/image-viewer/image-viewer.json +1 -0
- package/registry/components/image-viewer/image-viewer.wxml +1 -0
- package/registry/components/image-viewer/image-viewer.wxs +7 -0
- package/registry/components/image-viewer/image-viewer.wxss +90 -0
- package/registry/components/image-viewer/index.js +1 -0
- package/registry/components/image-viewer/props.js +1 -0
- package/registry/components/info-card/index.js +2 -0
- package/registry/components/info-card/info-card.js +22 -0
- package/registry/components/info-card/info-card.json +1 -0
- package/registry/components/info-card/info-card.wxml +14 -0
- package/registry/components/info-card/info-card.wxss +56 -0
- package/registry/components/info-card/props.js +11 -0
- package/registry/components/input/index.js +1 -0
- package/registry/components/input/input.js +1 -0
- package/registry/components/input/input.json +1 -0
- package/registry/components/input/input.wxml +1 -0
- package/registry/components/input/input.wxs +16 -0
- package/registry/components/input/input.wxss +313 -0
- package/registry/components/input/props.js +1 -0
- package/registry/components/insight-card/index.js +2 -0
- package/registry/components/insight-card/insight-card.js +19 -0
- package/registry/components/insight-card/insight-card.json +1 -0
- package/registry/components/insight-card/insight-card.wxml +17 -0
- package/registry/components/insight-card/insight-card.wxss +35 -0
- package/registry/components/insight-card/props.js +12 -0
- package/registry/components/link/index.js +1 -0
- package/registry/components/link/link.js +1 -0
- package/registry/components/link/link.json +1 -0
- package/registry/components/link/link.wxml +1 -0
- package/registry/components/link/link.wxss +155 -0
- package/registry/components/link/props.js +1 -0
- package/registry/components/list-item/index.js +2 -0
- package/registry/components/list-item/list-item.js +39 -0
- package/registry/components/list-item/list-item.json +1 -0
- package/registry/components/list-item/list-item.wxml +22 -0
- package/registry/components/list-item/list-item.wxss +110 -0
- package/registry/components/list-item/props.js +22 -0
- package/registry/components/loading/index.js +1 -0
- package/registry/components/loading/loading.js +1 -0
- package/registry/components/loading/loading.json +1 -0
- package/registry/components/loading/loading.wxml +1 -0
- package/registry/components/loading/loading.wxss +281 -0
- package/registry/components/loading/props.js +1 -0
- package/registry/components/main-card/index.js +2 -0
- package/registry/components/main-card/main-card.js +23 -0
- package/registry/components/main-card/main-card.json +1 -0
- package/registry/components/main-card/main-card.wxml +37 -0
- package/registry/components/main-card/main-card.wxss +63 -0
- package/registry/components/main-card/props.js +24 -0
- package/registry/components/media-card/index.js +2 -0
- package/registry/components/media-card/media-card.js +23 -0
- package/registry/components/media-card/media-card.json +1 -0
- package/registry/components/media-card/media-card.wxml +11 -0
- package/registry/components/media-card/media-card.wxss +51 -0
- package/registry/components/media-card/props.js +8 -0
- package/registry/components/message/index.js +1 -0
- package/registry/components/message/message.interface.js +1 -0
- package/registry/components/message/message.js +1 -0
- package/registry/components/message/message.json +1 -0
- package/registry/components/message/message.wxml +1 -0
- package/registry/components/message/message.wxss +2 -0
- package/registry/components/message/props.js +1 -0
- package/registry/components/message-item/index.js +1 -0
- package/registry/components/message-item/message-item.js +1 -0
- package/registry/components/message-item/message-item.json +1 -0
- package/registry/components/message-item/message-item.wxml +1 -0
- package/registry/components/message-item/message-item.wxs +31 -0
- package/registry/components/message-item/message-item.wxss +141 -0
- package/registry/components/navbar/index.js +1 -0
- package/registry/components/navbar/navbar.js +1 -0
- package/registry/components/navbar/navbar.json +1 -0
- package/registry/components/navbar/navbar.wxml +1 -0
- package/registry/components/navbar/navbar.wxss +126 -0
- package/registry/components/navbar/props.js +1 -0
- package/registry/components/notice-bar/index.js +1 -0
- package/registry/components/notice-bar/notice-bar.js +1 -0
- package/registry/components/notice-bar/notice-bar.json +1 -0
- package/registry/components/notice-bar/notice-bar.wxml +1 -0
- package/registry/components/notice-bar/notice-bar.wxss +95 -0
- package/registry/components/notice-bar/props.js +1 -0
- package/registry/components/notification-item/index.js +2 -0
- package/registry/components/notification-item/notification-item.js +35 -0
- package/registry/components/notification-item/notification-item.json +1 -0
- package/registry/components/notification-item/notification-item.wxml +14 -0
- package/registry/components/notification-item/notification-item.wxss +47 -0
- package/registry/components/notification-item/props.js +10 -0
- package/registry/components/offer-card/index.js +2 -0
- package/registry/components/offer-card/offer-card.js +22 -0
- package/registry/components/offer-card/offer-card.json +1 -0
- package/registry/components/offer-card/offer-card.wxml +33 -0
- package/registry/components/offer-card/offer-card.wxss +37 -0
- package/registry/components/offer-card/props.js +21 -0
- package/registry/components/om-card/index.js +2 -0
- package/registry/components/om-card/om-card.js +40 -0
- package/registry/components/om-card/om-card.json +1 -0
- package/registry/components/om-card/om-card.wxml +35 -0
- package/registry/components/om-card/om-card.wxss +90 -0
- package/registry/components/om-card/props.js +14 -0
- package/registry/components/overlay/index.js +1 -0
- package/registry/components/overlay/overlay.js +1 -0
- package/registry/components/overlay/overlay.json +1 -0
- package/registry/components/overlay/overlay.wxml +1 -0
- package/registry/components/overlay/overlay.wxss +22 -0
- package/registry/components/overlay/props.js +1 -0
- package/registry/components/paragraph/index.js +1 -0
- package/registry/components/paragraph/paragraph.js +1 -0
- package/registry/components/paragraph/paragraph.json +1 -0
- package/registry/components/paragraph/paragraph.wxml +1 -0
- package/registry/components/paragraph/paragraph.wxss +151 -0
- package/registry/components/paragraph/props.js +1 -0
- package/registry/components/picker/index.js +1 -0
- package/registry/components/picker/picker.js +1 -0
- package/registry/components/picker/picker.json +1 -0
- package/registry/components/picker/picker.wxml +1 -0
- package/registry/components/picker/picker.wxs +9 -0
- package/registry/components/picker/picker.wxss +84 -0
- package/registry/components/picker/props.js +1 -0
- package/registry/components/picker/template.wxml +1 -0
- package/registry/components/picker-item/index.js +1 -0
- package/registry/components/picker-item/picker-item.js +1 -0
- package/registry/components/picker-item/picker-item.json +1 -0
- package/registry/components/picker-item/picker-item.wxml +1 -0
- package/registry/components/picker-item/picker-item.wxss +41 -0
- package/registry/components/picker-item/props.js +1 -0
- package/registry/components/popover/index.js +1 -0
- package/registry/components/popover/popover.js +1 -0
- package/registry/components/popover/popover.json +1 -0
- package/registry/components/popover/popover.wxml +1 -0
- package/registry/components/popover/popover.wxss +336 -0
- package/registry/components/popover/props.js +1 -0
- package/registry/components/popup/index.js +1 -0
- package/registry/components/popup/popup.js +1 -0
- package/registry/components/popup/popup.json +1 -0
- package/registry/components/popup/popup.wxml +1 -0
- package/registry/components/popup/popup.wxs +21 -0
- package/registry/components/popup/popup.wxss +96 -0
- package/registry/components/popup/props.js +1 -0
- package/registry/components/post-item/index.js +2 -0
- package/registry/components/post-item/post-item.js +22 -0
- package/registry/components/post-item/post-item.json +1 -0
- package/registry/components/post-item/post-item.wxml +5 -0
- package/registry/components/post-item/post-item.wxss +37 -0
- package/registry/components/post-item/props.js +7 -0
- package/registry/components/progress/index.js +1 -0
- package/registry/components/progress/progress.js +1 -0
- package/registry/components/progress/progress.json +1 -0
- package/registry/components/progress/progress.wxml +1 -0
- package/registry/components/progress/progress.wxs +80 -0
- package/registry/components/progress/progress.wxss +161 -0
- package/registry/components/progress/props.js +1 -0
- package/registry/components/progress/utils.js +1 -0
- package/registry/components/purchase-card/index.js +2 -0
- package/registry/components/purchase-card/props.js +13 -0
- package/registry/components/purchase-card/purchase-card.js +40 -0
- package/registry/components/purchase-card/purchase-card.json +1 -0
- package/registry/components/purchase-card/purchase-card.wxml +22 -0
- package/registry/components/purchase-card/purchase-card.wxss +19 -0
- package/registry/components/qrcode/components/qrcode-canvas/props.js +1 -0
- package/registry/components/qrcode/components/qrcode-canvas/qrcode-canvas.js +1 -0
- package/registry/components/qrcode/components/qrcode-canvas/qrcode-canvas.json +1 -0
- package/registry/components/qrcode/components/qrcode-canvas/qrcode-canvas.wxml +1 -0
- package/registry/components/qrcode/components/qrcode-canvas/qrcode-canvas.wxss +10 -0
- package/registry/components/qrcode/components/qrcode-status/props.js +1 -0
- package/registry/components/qrcode/components/qrcode-status/qrcode-status.js +1 -0
- package/registry/components/qrcode/components/qrcode-status/qrcode-status.json +1 -0
- package/registry/components/qrcode/components/qrcode-status/qrcode-status.wxml +1 -0
- package/registry/components/qrcode/components/qrcode-status/qrcode-status.wxss +32 -0
- package/registry/components/qrcode/hooks/useQRCode.js +1 -0
- package/registry/components/qrcode/index.js +1 -0
- package/registry/components/qrcode/props.js +1 -0
- package/registry/components/qrcode/qrcode.js +1 -0
- package/registry/components/qrcode/qrcode.json +1 -0
- package/registry/components/qrcode/qrcode.wxml +1 -0
- package/registry/components/qrcode/qrcode.wxss +36 -0
- package/registry/components/quick-action/index.js +2 -0
- package/registry/components/quick-action/props.js +10 -0
- package/registry/components/quick-action/quick-action.js +22 -0
- package/registry/components/quick-action/quick-action.json +1 -0
- package/registry/components/quick-action/quick-action.wxml +15 -0
- package/registry/components/quick-action/quick-action.wxss +80 -0
- package/registry/components/radio/index.js +1 -0
- package/registry/components/radio/props.js +1 -0
- package/registry/components/radio/radio.js +1 -0
- package/registry/components/radio/radio.json +1 -0
- package/registry/components/radio/radio.wxml +1 -0
- package/registry/components/radio/radio.wxss +219 -0
- package/registry/components/radio-group/index.js +1 -0
- package/registry/components/radio-group/props.js +1 -0
- package/registry/components/radio-group/radio-group.js +1 -0
- package/registry/components/radio-group/radio-group.json +1 -0
- package/registry/components/radio-group/radio-group.wxml +1 -0
- package/registry/components/radio-group/radio-group.wxss +7 -0
- package/registry/components/rate/index.js +1 -0
- package/registry/components/rate/props.js +1 -0
- package/registry/components/rate/rate.js +1 -0
- package/registry/components/rate/rate.json +1 -0
- package/registry/components/rate/rate.wxml +1 -0
- package/registry/components/rate/rate.wxs +65 -0
- package/registry/components/rate/rate.wxss +99 -0
- package/registry/components/rating-card/index.js +2 -0
- package/registry/components/rating-card/props.js +12 -0
- package/registry/components/rating-card/rating-card.js +42 -0
- package/registry/components/rating-card/rating-card.json +1 -0
- package/registry/components/rating-card/rating-card.wxml +24 -0
- package/registry/components/rating-card/rating-card.wxss +49 -0
- package/registry/components/recap-card/index.js +2 -0
- package/registry/components/recap-card/props.js +21 -0
- package/registry/components/recap-card/recap-card.js +38 -0
- package/registry/components/recap-card/recap-card.json +1 -0
- package/registry/components/recap-card/recap-card.wxml +43 -0
- package/registry/components/recap-card/recap-card.wxss +60 -0
- package/registry/components/result/illustrations.js +2 -0
- package/registry/components/result/index.js +1 -0
- package/registry/components/result/props.js +1 -0
- package/registry/components/result/result.js +1 -0
- package/registry/components/result/result.json +1 -0
- package/registry/components/result/result.wxml +1 -0
- package/registry/components/result/result.wxss +97 -0
- package/registry/components/review-item/index.js +2 -0
- package/registry/components/review-item/props.js +13 -0
- package/registry/components/review-item/review-item.js +38 -0
- package/registry/components/review-item/review-item.json +1 -0
- package/registry/components/review-item/review-item.wxml +19 -0
- package/registry/components/review-item/review-item.wxss +65 -0
- package/registry/components/search/index.js +1 -0
- package/registry/components/search/props.js +1 -0
- package/registry/components/search/search.js +1 -0
- package/registry/components/search/search.json +1 -0
- package/registry/components/search/search.wxml +1 -0
- package/registry/components/search/search.wxs +6 -0
- package/registry/components/search/search.wxss +100 -0
- package/registry/components/section-title/index.js +2 -0
- package/registry/components/section-title/props.js +6 -0
- package/registry/components/section-title/section-title.js +22 -0
- package/registry/components/section-title/section-title.json +1 -0
- package/registry/components/section-title/section-title.wxml +6 -0
- package/registry/components/section-title/section-title.wxss +19 -0
- package/registry/components/segmented/index.js +1 -0
- package/registry/components/segmented/props.js +1 -0
- package/registry/components/segmented/segmented.js +1 -0
- package/registry/components/segmented/segmented.json +1 -0
- package/registry/components/segmented/segmented.wxml +1 -0
- package/registry/components/segmented/segmented.wxss +113 -0
- package/registry/components/selection-card/index.js +2 -0
- package/registry/components/selection-card/props.js +11 -0
- package/registry/components/selection-card/selection-card.js +25 -0
- package/registry/components/selection-card/selection-card.json +1 -0
- package/registry/components/selection-card/selection-card.wxml +7 -0
- package/registry/components/selection-card/selection-card.wxss +27 -0
- package/registry/components/shortcut-chip/index.js +2 -0
- package/registry/components/shortcut-chip/props.js +7 -0
- package/registry/components/shortcut-chip/shortcut-chip.js +24 -0
- package/registry/components/shortcut-chip/shortcut-chip.json +1 -0
- package/registry/components/shortcut-chip/shortcut-chip.wxml +4 -0
- package/registry/components/shortcut-chip/shortcut-chip.wxss +29 -0
- package/registry/components/skeleton/index.js +1 -0
- package/registry/components/skeleton/props.js +1 -0
- package/registry/components/skeleton/skeleton.js +1 -0
- package/registry/components/skeleton/skeleton.json +1 -0
- package/registry/components/skeleton/skeleton.wxml +1 -0
- package/registry/components/skeleton/skeleton.wxss +92 -0
- package/registry/components/slider/index.js +1 -0
- package/registry/components/slider/props.js +1 -0
- package/registry/components/slider/slider.js +1 -0
- package/registry/components/slider/slider.json +1 -0
- package/registry/components/slider/slider.wxml +1 -0
- package/registry/components/slider/slider.wxs +10 -0
- package/registry/components/slider/slider.wxss +287 -0
- package/registry/components/slider/tool.js +1 -0
- package/registry/components/step-item/index.js +1 -0
- package/registry/components/step-item/props.js +1 -0
- package/registry/components/step-item/step-item.js +1 -0
- package/registry/components/step-item/step-item.json +1 -0
- package/registry/components/step-item/step-item.wxml +1 -0
- package/registry/components/step-item/step-item.wxs +7 -0
- package/registry/components/step-item/step-item.wxss +226 -0
- package/registry/components/stepper/index.js +1 -0
- package/registry/components/stepper/props.js +1 -0
- package/registry/components/stepper/stepper.js +1 -0
- package/registry/components/stepper/stepper.json +1 -0
- package/registry/components/stepper/stepper.wxml +1 -0
- package/registry/components/stepper/stepper.wxss +130 -0
- package/registry/components/steps/index.js +1 -0
- package/registry/components/steps/props.js +1 -0
- package/registry/components/steps/steps.js +1 -0
- package/registry/components/steps/steps.json +1 -0
- package/registry/components/steps/steps.wxml +1 -0
- package/registry/components/steps/steps.wxss +27 -0
- package/registry/components/sticky/index.js +1 -0
- package/registry/components/sticky/props.js +1 -0
- package/registry/components/sticky/sticky.js +1 -0
- package/registry/components/sticky/sticky.json +1 -0
- package/registry/components/sticky/sticky.wxml +1 -0
- package/registry/components/sticky/sticky.wxss +6 -0
- package/registry/components/story-item/index.js +2 -0
- package/registry/components/story-item/props.js +8 -0
- package/registry/components/story-item/story-item.js +22 -0
- package/registry/components/story-item/story-item.json +1 -0
- package/registry/components/story-item/story-item.wxml +9 -0
- package/registry/components/story-item/story-item.wxss +43 -0
- package/registry/components/swipe-cell/index.js +1 -0
- package/registry/components/swipe-cell/props.js +1 -0
- package/registry/components/swipe-cell/swipe-cell.js +1 -0
- package/registry/components/swipe-cell/swipe-cell.json +1 -0
- package/registry/components/swipe-cell/swipe-cell.wxml +1 -0
- package/registry/components/swipe-cell/swipe-cell.wxs +185 -0
- package/registry/components/swipe-cell/swipe-cell.wxss +40 -0
- package/registry/components/swiper/index.js +1 -0
- package/registry/components/swiper/index.wxs +25 -0
- package/registry/components/swiper/props.js +1 -0
- package/registry/components/swiper/swiper.js +1 -0
- package/registry/components/swiper/swiper.json +1 -0
- package/registry/components/swiper/swiper.wxml +1 -0
- package/registry/components/swiper/swiper.wxss +28 -0
- package/registry/components/swiper-nav/index.js +1 -0
- package/registry/components/swiper-nav/props.js +1 -0
- package/registry/components/swiper-nav/swiper-nav.js +1 -0
- package/registry/components/swiper-nav/swiper-nav.json +1 -0
- package/registry/components/swiper-nav/swiper-nav.wxml +1 -0
- package/registry/components/swiper-nav/swiper-nav.wxss +155 -0
- package/registry/components/switch/index.js +1 -0
- package/registry/components/switch/props.js +1 -0
- package/registry/components/switch/switch.js +1 -0
- package/registry/components/switch/switch.json +1 -0
- package/registry/components/switch/switch.wxml +1 -0
- package/registry/components/switch/switch.wxss +169 -0
- package/registry/components/tab-bar/index.js +1 -0
- package/registry/components/tab-bar/props.js +1 -0
- package/registry/components/tab-bar/tab-bar.js +1 -0
- package/registry/components/tab-bar/tab-bar.json +1 -0
- package/registry/components/tab-bar/tab-bar.wxml +1 -0
- package/registry/components/tab-bar/tab-bar.wxss +50 -0
- package/registry/components/tab-bar-item/index.js +1 -0
- package/registry/components/tab-bar-item/props.js +1 -0
- package/registry/components/tab-bar-item/tab-bar-item.js +1 -0
- package/registry/components/tab-bar-item/tab-bar-item.json +1 -0
- package/registry/components/tab-bar-item/tab-bar-item.wxml +1 -0
- package/registry/components/tab-bar-item/tab-bar-item.wxss +177 -0
- package/registry/components/tab-panel/index.js +1 -0
- package/registry/components/tab-panel/props.js +1 -0
- package/registry/components/tab-panel/tab-panel.js +1 -0
- package/registry/components/tab-panel/tab-panel.json +1 -0
- package/registry/components/tab-panel/tab-panel.wxml +1 -0
- package/registry/components/tab-panel/tab-panel.wxss +20 -0
- package/registry/components/tabs/index.js +1 -0
- package/registry/components/tabs/props.js +1 -0
- package/registry/components/tabs/tabs.js +1 -0
- package/registry/components/tabs/tabs.json +1 -0
- package/registry/components/tabs/tabs.wxml +1 -0
- package/registry/components/tabs/tabs.wxs +30 -0
- package/registry/components/tabs/tabs.wxss +233 -0
- package/registry/components/tag/index.js +1 -0
- package/registry/components/tag/props.js +1 -0
- package/registry/components/tag/tag.js +1 -0
- package/registry/components/tag/tag.json +1 -0
- package/registry/components/tag/tag.wxml +1 -0
- package/registry/components/tag/tag.wxss +268 -0
- package/registry/components/text/index.js +1 -0
- package/registry/components/text/props.js +1 -0
- package/registry/components/text/text.js +1 -0
- package/registry/components/text/text.json +1 -0
- package/registry/components/text/text.wxml +1 -0
- package/registry/components/text/text.wxss +151 -0
- package/registry/components/textarea/index.js +1 -0
- package/registry/components/textarea/props.js +1 -0
- package/registry/components/textarea/textarea.js +1 -0
- package/registry/components/textarea/textarea.json +1 -0
- package/registry/components/textarea/textarea.wxml +1 -0
- package/registry/components/textarea/textarea.wxs +15 -0
- package/registry/components/textarea/textarea.wxss +151 -0
- package/registry/components/ticket/index.js +2 -0
- package/registry/components/ticket/props.js +19 -0
- package/registry/components/ticket/ticket.js +19 -0
- package/registry/components/ticket/ticket.json +1 -0
- package/registry/components/ticket/ticket.wxml +31 -0
- package/registry/components/ticket/ticket.wxss +57 -0
- package/registry/components/title/index.js +1 -0
- package/registry/components/title/props.js +1 -0
- package/registry/components/title/title.js +1 -0
- package/registry/components/title/title.json +1 -0
- package/registry/components/title/title.wxml +1 -0
- package/registry/components/title/title.wxss +151 -0
- package/registry/components/toast/index.js +1 -0
- package/registry/components/toast/props.js +1 -0
- package/registry/components/toast/toast.js +1 -0
- package/registry/components/toast/toast.json +1 -0
- package/registry/components/toast/toast.wxml +1 -0
- package/registry/components/toast/toast.wxss +87 -0
- package/registry/components/toggle-card/index.js +2 -0
- package/registry/components/toggle-card/props.js +7 -0
- package/registry/components/toggle-card/toggle-card.js +37 -0
- package/registry/components/toggle-card/toggle-card.json +1 -0
- package/registry/components/toggle-card/toggle-card.wxml +12 -0
- package/registry/components/toggle-card/toggle-card.wxss +11 -0
- package/registry/components/top-item/index.js +2 -0
- package/registry/components/top-item/props.js +10 -0
- package/registry/components/top-item/top-item.js +22 -0
- package/registry/components/top-item/top-item.json +1 -0
- package/registry/components/top-item/top-item.wxml +8 -0
- package/registry/components/top-item/top-item.wxss +37 -0
- package/registry/components/transaction-card/index.js +2 -0
- package/registry/components/transaction-card/props.js +25 -0
- package/registry/components/transaction-card/transaction-card.js +43 -0
- package/registry/components/transaction-card/transaction-card.json +1 -0
- package/registry/components/transaction-card/transaction-card.wxml +44 -0
- package/registry/components/transaction-card/transaction-card.wxss +45 -0
- package/registry/components/transfer-item/index.js +2 -0
- package/registry/components/transfer-item/props.js +18 -0
- package/registry/components/transfer-item/transfer-item.js +40 -0
- package/registry/components/transfer-item/transfer-item.json +1 -0
- package/registry/components/transfer-item/transfer-item.wxml +34 -0
- package/registry/components/transfer-item/transfer-item.wxss +66 -0
- package/registry/components/upload/drag.wxs +242 -0
- package/registry/components/upload/index.js +1 -0
- package/registry/components/upload/props.js +1 -0
- package/registry/components/upload/upload.js +1 -0
- package/registry/components/upload/upload.json +1 -0
- package/registry/components/upload/upload.wxml +1 -0
- package/registry/components/upload/upload.wxs +129 -0
- package/registry/components/upload/upload.wxss +354 -0
- package/registry/components/wheel-select/index.js +2 -0
- package/registry/components/wheel-select/props.js +8 -0
- package/registry/components/wheel-select/wheel-select.js +38 -0
- package/registry/components/wheel-select/wheel-select.json +1 -0
- package/registry/components/wheel-select/wheel-select.wxml +9 -0
- package/registry/components/wheel-select/wheel-select.wxss +22 -0
- package/registry/registry.json +1033 -0
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
@import '../common/style/index.wxss';
|
|
2
|
+
|
|
3
|
+
/* List item (Figma "atom_list item", M3): 56px (1 line) / 72px (2 lines), padding 8/24/8/16, gap 16px. */
|
|
4
|
+
.o-list-item {
|
|
5
|
+
position: relative;
|
|
6
|
+
display: flex;
|
|
7
|
+
align-items: center;
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
min-height: var(--o-list-item-height, 112rpx);
|
|
10
|
+
padding: var(--o-list-item-padding, 16rpx 48rpx 16rpx 32rpx);
|
|
11
|
+
background-color: var(--o-list-item-bg-color, var(--o-scheme-surface, #fff));
|
|
12
|
+
color: var(--o-scheme-on-surface, #1c1b1f);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.o-list-item--multi {
|
|
16
|
+
min-height: var(--o-list-item-multi-height, 144rpx);
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.o-list-item--hover {
|
|
20
|
+
background-color: var(--o-list-item-hover-bg-color, var(--o-scheme-surface-variant, #eee));
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.o-list-item--disabled {
|
|
24
|
+
opacity: .38;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.o-list-item--divider::after {
|
|
28
|
+
content: '';
|
|
29
|
+
position: absolute;
|
|
30
|
+
left: 0;
|
|
31
|
+
right: 0;
|
|
32
|
+
bottom: 0;
|
|
33
|
+
height: 1px;
|
|
34
|
+
transform: scaleY(.5);
|
|
35
|
+
background-color: var(--o-list-item-divider-color, var(--o-scheme-outline-variant, #ddd));
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.o-list-item__leading,
|
|
39
|
+
.o-list-item__trailing {
|
|
40
|
+
display: flex;
|
|
41
|
+
flex: none;
|
|
42
|
+
align-items: center;
|
|
43
|
+
gap: 16rpx;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.o-list-item__leading {
|
|
47
|
+
margin-right: var(--o-list-item-gap, 32rpx);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.o-list-item__trailing {
|
|
51
|
+
margin-left: var(--o-list-item-gap, 32rpx);
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.o-list-item__icon {
|
|
55
|
+
font-size: 48rpx;
|
|
56
|
+
color: var(--o-list-item-icon-color, var(--o-scheme-on-surface-variant, #444748));
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.o-list-item__avatar {
|
|
60
|
+
display: flex;
|
|
61
|
+
align-items: center;
|
|
62
|
+
justify-content: center;
|
|
63
|
+
width: 80rpx;
|
|
64
|
+
height: 80rpx;
|
|
65
|
+
border-radius: 50%;
|
|
66
|
+
overflow: hidden;
|
|
67
|
+
background-color: var(--o-list-item-avatar-bg-color, var(--o-scheme-secondary-container, #ffe2c9));
|
|
68
|
+
color: var(--o-scheme-on-secondary-container, #000);
|
|
69
|
+
font: var(--o-type-title-medium, 500 32rpx / 48rpx var(--o-font-family, Roboto, Arial));
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.o-list-item__image {
|
|
73
|
+
width: 112rpx;
|
|
74
|
+
height: 112rpx;
|
|
75
|
+
border-radius: 8rpx;
|
|
76
|
+
overflow: hidden;
|
|
77
|
+
background-color: var(--o-scheme-surface-variant, #eee);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.o-list-item__content {
|
|
81
|
+
flex: 1;
|
|
82
|
+
min-width: 0;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.o-list-item__overline {
|
|
86
|
+
font: var(--o-type-label-medium, 500 24rpx / 32rpx var(--o-font-family, Roboto, Arial));
|
|
87
|
+
color: var(--o-scheme-on-surface-variant, #444748);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
.o-list-item__title {
|
|
91
|
+
font: var(--o-type-body-large, 400 32rpx / 48rpx var(--o-font-family, Roboto, Arial));
|
|
92
|
+
color: var(--o-scheme-on-surface, #1c1b1f);
|
|
93
|
+
overflow: hidden;
|
|
94
|
+
white-space: nowrap;
|
|
95
|
+
text-overflow: ellipsis;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.o-list-item__description {
|
|
99
|
+
font: var(--o-type-body-medium, 400 28rpx / 40rpx var(--o-font-family, Roboto, Arial));
|
|
100
|
+
color: var(--o-scheme-on-surface-variant, #444748);
|
|
101
|
+
display: -webkit-box;
|
|
102
|
+
-webkit-box-orient: vertical;
|
|
103
|
+
-webkit-line-clamp: 2;
|
|
104
|
+
overflow: hidden;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.o-list-item__meta {
|
|
108
|
+
font: var(--o-type-label-small, 500 22rpx / 32rpx var(--o-font-family, Roboto, Arial));
|
|
109
|
+
color: var(--o-scheme-on-surface-variant, #444748);
|
|
110
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
// o-list-item: list item of the Max it design system (Figma "atom_list item", Material 3).
|
|
2
|
+
const props = {
|
|
3
|
+
// Texts
|
|
4
|
+
title: { type: String, value: '' },
|
|
5
|
+
overline: { type: String, value: '' },
|
|
6
|
+
description: { type: String, value: '' },
|
|
7
|
+
// Short text on the right (amount, date, "100+"...)
|
|
8
|
+
meta: { type: String, value: '' },
|
|
9
|
+
// Leading element: icon name, avatar (image url or initials) or thumbnail image url
|
|
10
|
+
leadingIcon: { type: String, value: '' },
|
|
11
|
+
avatar: { type: String, value: '' },
|
|
12
|
+
image: { type: String, value: '' },
|
|
13
|
+
// true when the `leading` slot is used (radio, checkbox, custom visual)
|
|
14
|
+
leading: { type: Boolean, value: false },
|
|
15
|
+
// Trailing element: icon name, or a chevron with `arrow`
|
|
16
|
+
trailingIcon: { type: String, value: '' },
|
|
17
|
+
arrow: { type: Boolean, value: false },
|
|
18
|
+
// Line under the item
|
|
19
|
+
divider: { type: Boolean, value: false },
|
|
20
|
+
disabled: { type: Boolean, value: false },
|
|
21
|
+
};
|
|
22
|
+
export default props;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export*from"./props";export*from"./loading";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{__decorate}from"../common/tslib";import{SuperComponent,wxComponent}from"../common/src/index";import config from"../common/config";import props from"./props";const{prefix:prefix}=config,name=`${prefix}-loading`;let Loading=class extends SuperComponent{constructor(){super(...arguments),this.externalClasses=[`${prefix}-class`,`${prefix}-class-text`,`${prefix}-class-indicator`],this.data={prefix:prefix,classPrefix:name,show:!0},this.options={multipleSlots:!0},this.properties=Object.assign({},props),this.timer=null,this.observers={loading(e){const{delay:t}=this.properties;this.timer&&clearTimeout(this.timer),e&&t?this.timer=setTimeout(()=>{this.setData({show:e}),this.timer=null},t):this.setData({show:e})}},this.lifetimes={detached(){clearTimeout(this.timer)}}}refreshPage(){this.triggerEvent("reload")}};Loading=__decorate([wxComponent()],Loading);export default Loading;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"component":true,"styleIsolation":"apply-shared","usingComponents":{}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<wxs src="../common/utils.wxs" module="_"/><view style="{{_._style([style, customStyle, show ? '' : 'display: none', inheritColor ? 'color: inherit' : ''])}}" class="class {{prefix}}-class {{classPrefix}} {{classPrefix + '--' + layout}} {{fullscreen ? classPrefix + '--fullscreen ' + classPrefix + '--overlay-' + overlay : ''}} {{textPlacement === 'top' ? classPrefix + '--text-top' : ''}}"><view wx:if="{{indicator}}" class="{{prefix}}-class-indicator {{classPrefix}}__spinner {{classPrefix}}__spinner--{{ theme }} {{reverse ? 'reverse' : ''}}" style="width: {{ _.addUnit(size) }}; height: {{ _.addUnit(size) }}; {{inheritColor ? 'color: inherit;' : ''}} {{indicator ? '' : 'display: none;'}} {{duration ? 'animation-duration: ' + duration / 1000 + 's;' : ''}} animation-play-state: {{pause ? 'paused' : 'running'}};" aria-role="{{ariaRole || 'img'}}" aria-label="{{ ariaLabel || text || 'Chargement' }}"><view wx:if="{{ theme === 'spinner' }}" wx:for="{{12}}" wx:key="index" class="{{classPrefix}}__dot {{classPrefix}}__dot-{{index}}"/><view wx:if="{{ theme === 'circular' }}" class="{{classPrefix}}__circular"/><view wx:if="{{ theme === 'ring' }}" class="{{classPrefix}}__ring"/><block wx:if="{{ theme === 'dots' }}"><view class="{{classPrefix}}__dot" style="{{duration ? 'animation-duration: ' + duration/1000 + 's; animation-delay:' + 0 + 's;' : ''}} animation-play-state: {{pause ? 'paused' : 'running'}};"></view><view class="{{classPrefix}}__dot" style="{{duration ? 'animation-duration: ' + duration/1000 + 's; animation-delay:' + duration * 1 / 3000 + 's;' : ''}} animation-play-state: {{pause ? 'paused' : 'running'}};"></view><view class="{{classPrefix}}__dot" style="{{duration ? 'animation-duration: ' + duration/1000 + 's; animation-delay:' + duration * 2 / 3000 + 's;' : ''}} animation-play-state: {{pause ? 'paused' : 'running'}};"></view></block><slot name="indicator"/></view><view class="{{_.cls(classPrefix + '__text', [layout])}} {{prefix}}-class-text" aria-hidden="{{indicator}}" aria-label="{{ ariaLabel || text }}"><block wx:if="{{text}}">{{text}}</block><slot name="text"/><slot/></view></view>
|
|
@@ -0,0 +1,281 @@
|
|
|
1
|
+
@import '../common/style/index.wxss';
|
|
2
|
+
|
|
3
|
+
.o-loading {
|
|
4
|
+
display: inline-flex;
|
|
5
|
+
align-items: center;
|
|
6
|
+
justify-content: center;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.o-loading--fullscreen {
|
|
10
|
+
position: fixed;
|
|
11
|
+
display: flex;
|
|
12
|
+
align-items: center;
|
|
13
|
+
vertical-align: middle;
|
|
14
|
+
justify-content: center;
|
|
15
|
+
top: 0;
|
|
16
|
+
left: 0;
|
|
17
|
+
width: 100%;
|
|
18
|
+
height: 100%;
|
|
19
|
+
z-index: var(--o-loading-z-index,3500);
|
|
20
|
+
background-color: var(--o-loading-full-bg-color,rgba(255,255,255,.6));
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.o-loading__spinner {
|
|
24
|
+
position: relative;
|
|
25
|
+
box-sizing: border-box;
|
|
26
|
+
width: 100%;
|
|
27
|
+
height: 100%;
|
|
28
|
+
max-width: 100%;
|
|
29
|
+
max-height: 100%;
|
|
30
|
+
animation: rotate .8s linear infinite;
|
|
31
|
+
color: var(--o-loading-color,var(--o-brand-color,var(--o-primary-color-7,#f16e00)));
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
.o-loading__spinner.reverse {
|
|
35
|
+
animation-name: rotateReverse;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
.o-loading__spinner--spinner {
|
|
39
|
+
animation-timing-function: steps(12);
|
|
40
|
+
color: var(--o-text-color-primary,var(--o-font-gray-1,#1c1b1f));
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
.o-loading__spinner--spinner .o-loading__dot {
|
|
44
|
+
position: absolute;
|
|
45
|
+
top: 0;
|
|
46
|
+
left: 0;
|
|
47
|
+
width: 100%;
|
|
48
|
+
height: 100%;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
.o-loading__spinner--spinner .o-loading__dot::before {
|
|
52
|
+
display: block;
|
|
53
|
+
width: 5rpx;
|
|
54
|
+
height: 25%;
|
|
55
|
+
margin: 0 auto;
|
|
56
|
+
background-color: var(--o-loading-color,var(--o-brand-color,var(--o-primary-color-7,#f16e00)));
|
|
57
|
+
border-radius: 40%;
|
|
58
|
+
content: ' ';
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.o-loading__spinner--circular .o-loading__circular {
|
|
62
|
+
border-radius: 100%;
|
|
63
|
+
width: 100%;
|
|
64
|
+
height: 100%;
|
|
65
|
+
background: conic-gradient(from 180deg at 50% 50%,rgba(255,255,255,0) 0deg,rgba(255,255,255,0) 60deg,currentColor 330deg,rgba(255,255,255,0) 360deg);
|
|
66
|
+
mask: radial-gradient(transparent calc(50% - 1rpx),#fff 50%);
|
|
67
|
+
-webkit-mask: radial-gradient(transparent calc(50% - 1rpx),#fff 50%);
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
.o-loading__spinner--dots {
|
|
71
|
+
display: flex;
|
|
72
|
+
justify-content: space-between;
|
|
73
|
+
align-items: center;
|
|
74
|
+
animation: none;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
.o-loading__spinner--dots .o-loading__dot {
|
|
78
|
+
width: 20%;
|
|
79
|
+
height: 20%;
|
|
80
|
+
border-radius: var(--o-radius-circle,50%);
|
|
81
|
+
background-color: var(--o-loading-color,var(--o-brand-color,var(--o-primary-color-7,#f16e00)));
|
|
82
|
+
animation-duration: 1.8s;
|
|
83
|
+
animation-name: dotting;
|
|
84
|
+
animation-timing-function: linear;
|
|
85
|
+
animation-iteration-count: infinite;
|
|
86
|
+
animation-fill-mode: both;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.o-loading__text {
|
|
90
|
+
color: var(--o-loading-text-color,var(--o-text-color-primary,var(--o-font-gray-1,#1c1b1f)));
|
|
91
|
+
font: var(--o-loading-text-font,var(--o-font-body-small,24rpx / 40rpx var(--o-font-family,Roboto,PingFang SC,Microsoft YaHei,Arial)));
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.o-loading__text--vertical:not(:first-child):not(:empty) {
|
|
95
|
+
margin-top: 12rpx;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
.o-loading__text--horizontal:not(:first-child):not(:empty) {
|
|
99
|
+
margin-left: var(--o-spacer,16rpx);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.o-loading--vertical {
|
|
103
|
+
flex-direction: column;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.o-loading--horizontal {
|
|
107
|
+
flex-direction: row;
|
|
108
|
+
vertical-align: top;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
@keyframes o-bar {
|
|
112
|
+
0% {
|
|
113
|
+
width: 0;
|
|
114
|
+
}
|
|
115
|
+
50% {
|
|
116
|
+
width: 70%;
|
|
117
|
+
}
|
|
118
|
+
100% {
|
|
119
|
+
width: 80%;
|
|
120
|
+
}
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
@keyframes o-bar-loaded {
|
|
124
|
+
0% {
|
|
125
|
+
height: 6rpx;
|
|
126
|
+
opacity: 1;
|
|
127
|
+
width: 90%;
|
|
128
|
+
}
|
|
129
|
+
50% {
|
|
130
|
+
height: 6rpx;
|
|
131
|
+
opacity: 1;
|
|
132
|
+
width: 100%;
|
|
133
|
+
}
|
|
134
|
+
100% {
|
|
135
|
+
height: 0;
|
|
136
|
+
opacity: 0;
|
|
137
|
+
width: 100%;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.o-loading__dot-1 {
|
|
142
|
+
transform: rotate(30deg);
|
|
143
|
+
opacity: 0;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
.o-loading__dot-2 {
|
|
147
|
+
transform: rotate(60deg);
|
|
148
|
+
opacity: .08333333;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
.o-loading__dot-3 {
|
|
152
|
+
transform: rotate(90deg);
|
|
153
|
+
opacity: .16666667;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.o-loading__dot-4 {
|
|
157
|
+
transform: rotate(120deg);
|
|
158
|
+
opacity: .25;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
.o-loading__dot-5 {
|
|
162
|
+
transform: rotate(150deg);
|
|
163
|
+
opacity: .33333333;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
.o-loading__dot-6 {
|
|
167
|
+
transform: rotate(180deg);
|
|
168
|
+
opacity: .41666667;
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
.o-loading__dot-7 {
|
|
172
|
+
transform: rotate(210deg);
|
|
173
|
+
opacity: .5;
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
.o-loading__dot-8 {
|
|
177
|
+
transform: rotate(240deg);
|
|
178
|
+
opacity: .58333333;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.o-loading__dot-9 {
|
|
182
|
+
transform: rotate(270deg);
|
|
183
|
+
opacity: .66666667;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.o-loading__dot-10 {
|
|
187
|
+
transform: rotate(300deg);
|
|
188
|
+
opacity: .75;
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
.o-loading__dot-11 {
|
|
192
|
+
transform: rotate(330deg);
|
|
193
|
+
opacity: .83333333;
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.o-loading__dot-12 {
|
|
197
|
+
transform: rotate(360deg);
|
|
198
|
+
opacity: .91666667;
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
@keyframes rotate {
|
|
202
|
+
from {
|
|
203
|
+
transform: rotate(0);
|
|
204
|
+
}
|
|
205
|
+
to {
|
|
206
|
+
transform: rotate(360deg);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
|
|
210
|
+
@keyframes rotateReverse {
|
|
211
|
+
from {
|
|
212
|
+
transform: rotate(360deg);
|
|
213
|
+
}
|
|
214
|
+
to {
|
|
215
|
+
transform: rotate(0);
|
|
216
|
+
}
|
|
217
|
+
}
|
|
218
|
+
|
|
219
|
+
@keyframes dotting {
|
|
220
|
+
0% {
|
|
221
|
+
opacity: .15;
|
|
222
|
+
}
|
|
223
|
+
1% {
|
|
224
|
+
opacity: .8;
|
|
225
|
+
}
|
|
226
|
+
33% {
|
|
227
|
+
opacity: .8;
|
|
228
|
+
}
|
|
229
|
+
34% {
|
|
230
|
+
opacity: .15;
|
|
231
|
+
}
|
|
232
|
+
100% {
|
|
233
|
+
opacity: .15;
|
|
234
|
+
}
|
|
235
|
+
}
|
|
236
|
+
|
|
237
|
+
.o-loading__spinner--ring .o-loading__ring {
|
|
238
|
+
box-sizing: border-box;
|
|
239
|
+
width: 100%;
|
|
240
|
+
height: 100%;
|
|
241
|
+
border-radius: 50%;
|
|
242
|
+
border: var(--o-loading-ring-width,16rpx) solid var(--o-loading-ring-track-color,#eeeeee);
|
|
243
|
+
border-top-color: currentColor;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
.o-loading--vertical.o-loading--text-top {
|
|
247
|
+
flex-direction: column-reverse;
|
|
248
|
+
}
|
|
249
|
+
|
|
250
|
+
.o-loading--horizontal.o-loading--text-top {
|
|
251
|
+
flex-direction: row-reverse;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
.o-loading--vertical.o-loading--text-top .o-loading__text--vertical:not(:empty) {
|
|
255
|
+
margin-top: 0;
|
|
256
|
+
margin-bottom: var(--o-loading-text-gap,48rpx);
|
|
257
|
+
}
|
|
258
|
+
|
|
259
|
+
.o-loading--horizontal.o-loading--text-top .o-loading__text--horizontal:not(:empty) {
|
|
260
|
+
margin-left: 0;
|
|
261
|
+
margin-right: var(--o-spacer,16rpx);
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
.o-loading--fullscreen .o-loading__text {
|
|
265
|
+
max-width: var(--o-loading-fullscreen-text-width,70%);
|
|
266
|
+
text-align: center;
|
|
267
|
+
font: var(--o-loading-fullscreen-text-font,28rpx / 40rpx var(--o-font-family,Roboto,PingFang SC,Microsoft YaHei,Arial));
|
|
268
|
+
}
|
|
269
|
+
|
|
270
|
+
.o-loading--overlay-light {
|
|
271
|
+
background-color: var(--o-loading-overlay-light-bg,rgba(255,255,255,.85));
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
.o-loading--overlay-dark {
|
|
275
|
+
background-color: var(--o-loading-overlay-dark-bg,rgba(0,0,0,.5));
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
.o-loading--overlay-dark .o-loading__text {
|
|
279
|
+
color: var(--o-loading-overlay-dark-text-color,#fff);
|
|
280
|
+
}
|
|
281
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
const props={textPlacement:{type:String,value:"bottom"},overlay:{type:String,value:"light"},delay:{type:Number,value:0},duration:{type:Number,value:800},fullscreen:{type:Boolean,value:!1},indicator:{type:Boolean,value:!0},inheritColor:{type:Boolean,value:!1},layout:{type:String,value:"horizontal"},loading:{type:Boolean,value:!0},pause:{type:Boolean,value:!1},progress:{type:Number},reverse:{type:Boolean},size:{type:String,value:"20px"},text:{type:String},theme:{type:String,value:"circular"}};export default props;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { __decorate } from '../common/tslib';
|
|
2
|
+
import { SuperComponent, wxComponent } from '../common/src/index';
|
|
3
|
+
import config from '../common/config';
|
|
4
|
+
import props from './props';
|
|
5
|
+
|
|
6
|
+
const { prefix } = config;
|
|
7
|
+
const name = `${prefix}-main-card`;
|
|
8
|
+
|
|
9
|
+
let MainCard = class MainCard extends SuperComponent {
|
|
10
|
+
constructor() {
|
|
11
|
+
super(...arguments);
|
|
12
|
+
this.externalClasses = [`${prefix}-class`];
|
|
13
|
+
this.options = { multipleSlots: true };
|
|
14
|
+
this.properties = props;
|
|
15
|
+
this.data = { prefix, classPrefix: name };
|
|
16
|
+
this.methods = {
|
|
17
|
+
onPrimary() { this.triggerEvent('primary'); },
|
|
18
|
+
onSecondary() { this.triggerEvent('secondary'); },
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
MainCard = __decorate([wxComponent()], MainCard);
|
|
23
|
+
export default MainCard;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"component":true,"styleIsolation":"apply-shared","usingComponents":{"o-icon":"../icon/icon","o-button":"../button/button"}}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
<view class="o-surface {{dark ? 'o-surface--dark' : 'o-surface--outlined'}} o-main-card class {{prefix}}-class" style="{{style}} {{customStyle}}">
|
|
2
|
+
<view class="o-main-card__media">
|
|
3
|
+
<image wx:if="{{image}}" class="o-main-card__image" src="{{image}}" mode="aspectFill" />
|
|
4
|
+
<o-icon wx:else name="image" o-class="o-main-card__placeholder" />
|
|
5
|
+
<view wx:if="{{logo}}" class="o-main-card__logo"><o-icon name="{{logo}}" /></view>
|
|
6
|
+
<view wx:if="{{tag}}" class="o-pill o-pill--black o-main-card__tag">{{tag}}</view>
|
|
7
|
+
</view>
|
|
8
|
+
<view class="o-pad">
|
|
9
|
+
<view class="o-row o-row--top">
|
|
10
|
+
<view class="o-thumb">
|
|
11
|
+
<image wx:if="{{thumbnail}}" class="o-thumb__image" src="{{thumbnail}}" mode="aspectFill" />
|
|
12
|
+
<o-icon wx:else name="{{thumbnailIcon}}" />
|
|
13
|
+
</view>
|
|
14
|
+
<view class="o-grow o-main-card__heading">
|
|
15
|
+
<view class="o-txt-title">{{title}}</view>
|
|
16
|
+
<view wx:if="{{subtitle}}" class="o-txt-body">{{subtitle}}</view>
|
|
17
|
+
<view wx:if="{{meta}}" class="o-txt-meta">{{meta}}</view>
|
|
18
|
+
<view wx:if="{{subtitle2}}" class="o-txt-body">{{subtitle2}}</view>
|
|
19
|
+
</view>
|
|
20
|
+
</view>
|
|
21
|
+
<view wx:if="{{description && variant !== 'promo'}}" class="o-txt-body o-main-card__description">{{description}}</view>
|
|
22
|
+
<view class="o-row o-main-card__bottom">
|
|
23
|
+
<view class="o-grow">
|
|
24
|
+
<view wx:if="{{supporting}}" class="o-txt-small">{{supporting}}</view>
|
|
25
|
+
<view wx:if="{{amount}}">
|
|
26
|
+
<text class="o-amount">{{amount}}</text><text class="o-amount__currency">{{currency}}</text>
|
|
27
|
+
<text wx:if="{{oldAmount}}" class="o-amount--old">{{oldAmount}} {{currency}}</text>
|
|
28
|
+
</view>
|
|
29
|
+
</view>
|
|
30
|
+
<o-button wx:if="{{variant === 'promo' && primaryText}}" theme="primary" bind:tap="onPrimary">{{primaryText}}</o-button>
|
|
31
|
+
</view>
|
|
32
|
+
<view wx:if="{{variant !== 'promo' && (primaryText || secondaryText)}}" class="o-main-card__actions">
|
|
33
|
+
<o-button wx:if="{{secondaryText}}" variant="outline" bind:tap="onSecondary">{{secondaryText}}</o-button>
|
|
34
|
+
<o-button wx:if="{{primaryText}}" theme="secondary" bind:tap="onPrimary">{{primaryText}}</o-button>
|
|
35
|
+
</view>
|
|
36
|
+
</view>
|
|
37
|
+
</view>
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
@import '../common/style/index.wxss';
|
|
2
|
+
@import '../common/style/card.wxss';
|
|
3
|
+
|
|
4
|
+
/* Main card (Figma "Main Cards" > Main card): media, tag, thumbnail, texts, price and actions. */
|
|
5
|
+
.o-main-card__media {
|
|
6
|
+
position: relative;
|
|
7
|
+
display: flex;
|
|
8
|
+
align-items: center;
|
|
9
|
+
justify-content: center;
|
|
10
|
+
height: 256rpx;
|
|
11
|
+
background-color: var(--o-scheme-surface-variant, #eee);
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
.o-main-card__image {
|
|
15
|
+
width: 100%;
|
|
16
|
+
height: 100%;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
.o-main-card__placeholder {
|
|
20
|
+
font-size: 128rpx;
|
|
21
|
+
color: var(--o-scheme-surface, #fff);
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.o-main-card__logo {
|
|
25
|
+
position: absolute;
|
|
26
|
+
top: 24rpx;
|
|
27
|
+
left: 24rpx;
|
|
28
|
+
display: flex;
|
|
29
|
+
align-items: center;
|
|
30
|
+
justify-content: center;
|
|
31
|
+
width: 80rpx;
|
|
32
|
+
height: 80rpx;
|
|
33
|
+
border-radius: 16rpx;
|
|
34
|
+
border: 2rpx solid var(--o-scheme-outline-variant, #ddd);
|
|
35
|
+
background-color: var(--o-scheme-surface, #fff);
|
|
36
|
+
color: var(--o-scheme-on-surface, #1c1b1f);
|
|
37
|
+
font-size: 48rpx;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.o-main-card__tag {
|
|
41
|
+
position: absolute;
|
|
42
|
+
top: 24rpx;
|
|
43
|
+
right: 24rpx;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.o-main-card__heading {
|
|
47
|
+
margin-left: 24rpx;
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
.o-main-card__description {
|
|
51
|
+
margin-top: 24rpx;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.o-main-card__bottom {
|
|
55
|
+
margin-top: 24rpx;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.o-main-card__actions {
|
|
59
|
+
display: flex;
|
|
60
|
+
justify-content: flex-end;
|
|
61
|
+
gap: 16rpx;
|
|
62
|
+
margin-top: 32rpx;
|
|
63
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
// o-main-card: Main card (Figma "Main Cards" > Main card): media, tag, thumbnail, texts, price and actions.
|
|
2
|
+
const props = {
|
|
3
|
+
// default: description + 2 buttons, promo: supporting text, old price and orange button
|
|
4
|
+
variant: { type: String, value: 'default' },
|
|
5
|
+
dark: { type: Boolean, value: false },
|
|
6
|
+
image: { type: String, value: '' },
|
|
7
|
+
// Icon shown in the white box at the top left of the media
|
|
8
|
+
logo: { type: String, value: '' },
|
|
9
|
+
tag: { type: String, value: '' },
|
|
10
|
+
thumbnail: { type: String, value: '' },
|
|
11
|
+
thumbnailIcon: { type: String, value: 'image' },
|
|
12
|
+
title: { type: String, value: '' },
|
|
13
|
+
subtitle: { type: String, value: '' },
|
|
14
|
+
meta: { type: String, value: '' },
|
|
15
|
+
subtitle2: { type: String, value: '' },
|
|
16
|
+
description: { type: String, value: '' },
|
|
17
|
+
supporting: { type: String, value: '' },
|
|
18
|
+
amount: { type: String, value: '' },
|
|
19
|
+
oldAmount: { type: String, value: '' },
|
|
20
|
+
currency: { type: String, value: 'FCFA' },
|
|
21
|
+
primaryText: { type: String, value: '' },
|
|
22
|
+
secondaryText: { type: String, value: '' },
|
|
23
|
+
};
|
|
24
|
+
export default props;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { __decorate } from '../common/tslib';
|
|
2
|
+
import { SuperComponent, wxComponent } from '../common/src/index';
|
|
3
|
+
import config from '../common/config';
|
|
4
|
+
import props from './props';
|
|
5
|
+
|
|
6
|
+
const { prefix } = config;
|
|
7
|
+
const name = `${prefix}-media-card`;
|
|
8
|
+
|
|
9
|
+
let MediaCard = class MediaCard extends SuperComponent {
|
|
10
|
+
constructor() {
|
|
11
|
+
super(...arguments);
|
|
12
|
+
this.externalClasses = [`${prefix}-class`];
|
|
13
|
+
this.options = { multipleSlots: true };
|
|
14
|
+
this.properties = props;
|
|
15
|
+
this.data = { prefix, classPrefix: name };
|
|
16
|
+
this.methods = {
|
|
17
|
+
onTap() { this.triggerEvent('click'); },
|
|
18
|
+
onPlay() { this.triggerEvent('play'); },
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
MediaCard = __decorate([wxComponent()], MediaCard);
|
|
23
|
+
export default MediaCard;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"component":true,"styleIsolation":"apply-shared","usingComponents":{"o-icon":"../icon/icon"}}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
<view class="o-surface o-media-card class {{prefix}}-class" style="{{style}} {{customStyle}}" bind:tap="onTap">
|
|
2
|
+
<view class="o-media-card__media">
|
|
3
|
+
<image wx:if="{{image}}" class="o-media-card__image" src="{{image}}" mode="aspectFill" />
|
|
4
|
+
<o-icon wx:else name="image" o-class="o-media-card__placeholder" />
|
|
5
|
+
<view wx:if="{{play}}" class="o-media-card__play" catch:tap="onPlay"><o-icon name="play" /></view>
|
|
6
|
+
</view>
|
|
7
|
+
<view class="o-media-card__bar">
|
|
8
|
+
<view class="o-txt-title">{{title}}</view>
|
|
9
|
+
<view wx:if="{{subtitle}}" class="o-media-card__subtitle">{{subtitle}}</view>
|
|
10
|
+
</view>
|
|
11
|
+
</view>
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
@import '../common/style/index.wxss';
|
|
2
|
+
@import '../common/style/card.wxss';
|
|
3
|
+
|
|
4
|
+
/* Media card (Figma "Main Cards" > Media card): picture, play button, title bar at the bottom. */
|
|
5
|
+
.o-media-card {
|
|
6
|
+
position: relative;
|
|
7
|
+
background-color: var(--o-scheme-surface-variant, #eee);
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.o-media-card__media {
|
|
11
|
+
display: flex;
|
|
12
|
+
align-items: center;
|
|
13
|
+
justify-content: center;
|
|
14
|
+
height: 300rpx;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.o-media-card__image {
|
|
18
|
+
width: 100%;
|
|
19
|
+
height: 100%;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.o-media-card__placeholder {
|
|
23
|
+
font-size: 160rpx;
|
|
24
|
+
color: var(--o-scheme-surface, #fff);
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.o-media-card__play {
|
|
28
|
+
position: absolute;
|
|
29
|
+
top: 24rpx;
|
|
30
|
+
right: 24rpx;
|
|
31
|
+
display: flex;
|
|
32
|
+
align-items: center;
|
|
33
|
+
justify-content: center;
|
|
34
|
+
width: 64rpx;
|
|
35
|
+
height: 64rpx;
|
|
36
|
+
border-radius: 50%;
|
|
37
|
+
background-color: #fff;
|
|
38
|
+
color: #000;
|
|
39
|
+
font-size: 40rpx;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
.o-media-card__bar {
|
|
43
|
+
padding: 20rpx 32rpx;
|
|
44
|
+
background-color: var(--o-static-primary-fixed, #242424);
|
|
45
|
+
color: #fff;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.o-media-card__subtitle {
|
|
49
|
+
font: var(--o-type-body-small, 400 24rpx / 32rpx var(--o-font-family, Roboto, Arial));
|
|
50
|
+
color: var(--o-static-on-primary-fixed-variant, #dedede);
|
|
51
|
+
}
|