@bitrise/bitkit-v2 0.3.280-beta.1864 → 0.3.280-beta.1866

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.
@@ -2,6 +2,7 @@ import { rem } from "../../theme/themeUtils.js";
2
2
  import { NotificationActionButton, NotificationCloseButton } from "../common/NotificationButtons.js";
3
3
  import { BUTTON_COLORS_MAP } from "../common/notificationMaps.js";
4
4
  import ForwardRef from "./mascot.js";
5
+ import { Box } from "@chakra-ui/react/box";
5
6
  import { Icon } from "@chakra-ui/react/icon";
6
7
  import { jsx, jsxs } from "react/jsx-runtime";
7
8
  import { Alert } from "@chakra-ui/react/alert";
@@ -24,13 +25,22 @@ var BitkitPromoBanner = (props) => {
24
25
  marginInlineStart: rem(-12),
25
26
  children: illustration ?? /* @__PURE__ */ jsx(ForwardRef, {})
26
27
  }),
27
- /* @__PURE__ */ jsxs(Alert.Content, {
28
+ /* @__PURE__ */ jsxs(Box, {
29
+ display: "flex",
30
+ flex: "1",
28
31
  minWidth: "0",
29
- children: [/* @__PURE__ */ jsx(Alert.Title, { children: title }), /* @__PURE__ */ jsx(Alert.Description, { children: message })]
30
- }),
31
- !!actionable && /* @__PURE__ */ jsx(NotificationActionButton, {
32
- action: actionable,
33
- colorVariant: PROMO_BANNER_COLOR
32
+ flexWrap: "wrap",
33
+ alignItems: "center",
34
+ columnGap: "16",
35
+ rowGap: rem(11),
36
+ children: [/* @__PURE__ */ jsxs(Alert.Content, {
37
+ minWidth: "0",
38
+ flex: `1 1 ${rem(240)}`,
39
+ children: [/* @__PURE__ */ jsx(Alert.Title, { children: title }), /* @__PURE__ */ jsx(Alert.Description, { children: message })]
40
+ }), !!actionable && /* @__PURE__ */ jsx(NotificationActionButton, {
41
+ action: actionable,
42
+ colorVariant: PROMO_BANNER_COLOR
43
+ })]
34
44
  }),
35
45
  !!dismissible && /* @__PURE__ */ jsx(NotificationCloseButton, {
36
46
  colorVariant: PROMO_BANNER_COLOR,
@@ -1 +1 @@
1
- {"version":3,"file":"BitkitPromoBanner.js","names":[],"sources":["../../../lib/components/BitkitPromoBanner/BitkitPromoBanner.tsx"],"sourcesContent":["import { Alert, type AlertRootProps } from '@chakra-ui/react/alert';\nimport { Icon } from '@chakra-ui/react/icon';\nimport { type ReactNode } from 'react';\n\nimport { rem } from '../../theme/themeUtils';\nimport { NotificationActionButton, NotificationCloseButton } from '../common/NotificationButtons';\nimport { BUTTON_COLORS_MAP, type NotificationAction } from '../common/notificationMaps';\nimport MascotSvg from './mascot.svg?react';\n\nexport type PromoBannerAction = NotificationAction;\n\nconst PROMO_BANNER_COLOR = BUTTON_COLORS_MAP.info;\n\nexport interface BitkitPromoBannerProps extends Omit<AlertRootProps, 'title' | 'variant'> {\n actionable?: PromoBannerAction;\n dismissible?: boolean;\n /** Custom leading illustration (an SVG element). Defaults to the built-in mascot. */\n illustration?: ReactNode;\n message: ReactNode;\n onClose?: () => void;\n title: ReactNode;\n}\n\nconst BitkitPromoBanner = (props: BitkitPromoBannerProps) => {\n const { actionable, dismissible, illustration, message, onClose, title, ...rest } = props;\n\n return (\n <Alert.Root variant=\"info\" border=\"none\" css={{ '& .alert__title + *': { marginBlockStart: 0 } }} {...rest}>\n <Icon\n asChild\n width={rem(72)}\n height={rem(68)}\n marginInlineEnd=\"12\"\n marginBlock={rem(-11)}\n marginInlineStart={rem(-12)}\n >\n {illustration ?? <MascotSvg />}\n </Icon>\n <Alert.Content minWidth=\"0\">\n <Alert.Title>{title}</Alert.Title>\n <Alert.Description>{message}</Alert.Description>\n </Alert.Content>\n {!!actionable && <NotificationActionButton action={actionable} colorVariant={PROMO_BANNER_COLOR} />}\n {!!dismissible && <NotificationCloseButton colorVariant={PROMO_BANNER_COLOR} onClose={onClose} />}\n </Alert.Root>\n );\n};\n\nBitkitPromoBanner.displayName = 'BitkitPromoBanner';\n\nexport default BitkitPromoBanner;\n"],"mappings":";;;;;;;;AAWA,IAAM,qBAAqB,kBAAkB;AAY7C,IAAM,qBAAqB,UAAkC;CAC3D,MAAM,EAAE,YAAY,aAAa,cAAc,SAAS,SAAS,OAAO,GAAG,SAAS;CAEpF,OACE,qBAAC,MAAM,MAAP;EAAY,SAAQ;EAAO,QAAO;EAAO,KAAK,EAAE,uBAAuB,EAAE,kBAAkB,EAAE,EAAE;EAAG,GAAI;YAAtG;GACE,oBAAC,MAAD;IACE,SAAA;IACA,OAAO,IAAI,EAAE;IACb,QAAQ,IAAI,EAAE;IACd,iBAAgB;IAChB,aAAa,IAAI,GAAG;IACpB,mBAAmB,IAAI,GAAG;cAEzB,gBAAgB,oBAAC,YAAD,CAAY,CAAA;GACzB,CAAA;GACN,qBAAC,MAAM,SAAP;IAAe,UAAS;cAAxB,CACE,oBAAC,MAAM,OAAP,EAAA,UAAc,MAAmB,CAAA,GACjC,oBAAC,MAAM,aAAP,EAAA,UAAoB,QAA2B,CAAA,CAClC;;GACd,CAAC,CAAC,cAAc,oBAAC,0BAAD;IAA0B,QAAQ;IAAY,cAAc;GAAqB,CAAA;GACjG,CAAC,CAAC,eAAe,oBAAC,yBAAD;IAAyB,cAAc;IAA6B;GAAU,CAAA;EACtF;;AAEhB;AAEA,kBAAkB,cAAc"}
1
+ {"version":3,"file":"BitkitPromoBanner.js","names":[],"sources":["../../../lib/components/BitkitPromoBanner/BitkitPromoBanner.tsx"],"sourcesContent":["import { Alert, type AlertRootProps } from '@chakra-ui/react/alert';\nimport { Box } from '@chakra-ui/react/box';\nimport { Icon } from '@chakra-ui/react/icon';\nimport { type ReactNode } from 'react';\n\nimport { rem } from '../../theme/themeUtils';\nimport { NotificationActionButton, NotificationCloseButton } from '../common/NotificationButtons';\nimport { BUTTON_COLORS_MAP, type NotificationAction } from '../common/notificationMaps';\nimport MascotSvg from './mascot.svg?react';\n\nexport type PromoBannerAction = NotificationAction;\n\nconst PROMO_BANNER_COLOR = BUTTON_COLORS_MAP.info;\n\nexport interface BitkitPromoBannerProps extends Omit<AlertRootProps, 'title' | 'variant'> {\n actionable?: PromoBannerAction;\n dismissible?: boolean;\n /** Custom leading illustration (an SVG element). Defaults to the built-in mascot. */\n illustration?: ReactNode;\n message: ReactNode;\n onClose?: () => void;\n title: ReactNode;\n}\n\nconst BitkitPromoBanner = (props: BitkitPromoBannerProps) => {\n const { actionable, dismissible, illustration, message, onClose, title, ...rest } = props;\n\n return (\n <Alert.Root variant=\"info\" border=\"none\" css={{ '& .alert__title + *': { marginBlockStart: 0 } }} {...rest}>\n <Icon\n asChild\n width={rem(72)}\n height={rem(68)}\n marginInlineEnd=\"12\"\n marginBlock={rem(-11)}\n marginInlineStart={rem(-12)}\n >\n {illustration ?? <MascotSvg />}\n </Icon>\n <Box display=\"flex\" flex=\"1\" minWidth=\"0\" flexWrap=\"wrap\" alignItems=\"center\" columnGap=\"16\" rowGap={rem(11)}>\n <Alert.Content minWidth=\"0\" flex={`1 1 ${rem(240)}`}>\n <Alert.Title>{title}</Alert.Title>\n <Alert.Description>{message}</Alert.Description>\n </Alert.Content>\n {!!actionable && <NotificationActionButton action={actionable} colorVariant={PROMO_BANNER_COLOR} />}\n </Box>\n {!!dismissible && <NotificationCloseButton colorVariant={PROMO_BANNER_COLOR} onClose={onClose} />}\n </Alert.Root>\n );\n};\n\nBitkitPromoBanner.displayName = 'BitkitPromoBanner';\n\nexport default BitkitPromoBanner;\n"],"mappings":";;;;;;;;;AAYA,IAAM,qBAAqB,kBAAkB;AAY7C,IAAM,qBAAqB,UAAkC;CAC3D,MAAM,EAAE,YAAY,aAAa,cAAc,SAAS,SAAS,OAAO,GAAG,SAAS;CAEpF,OACE,qBAAC,MAAM,MAAP;EAAY,SAAQ;EAAO,QAAO;EAAO,KAAK,EAAE,uBAAuB,EAAE,kBAAkB,EAAE,EAAE;EAAG,GAAI;YAAtG;GACE,oBAAC,MAAD;IACE,SAAA;IACA,OAAO,IAAI,EAAE;IACb,QAAQ,IAAI,EAAE;IACd,iBAAgB;IAChB,aAAa,IAAI,GAAG;IACpB,mBAAmB,IAAI,GAAG;cAEzB,gBAAgB,oBAAC,YAAD,CAAY,CAAA;GACzB,CAAA;GACN,qBAAC,KAAD;IAAK,SAAQ;IAAO,MAAK;IAAI,UAAS;IAAI,UAAS;IAAO,YAAW;IAAS,WAAU;IAAK,QAAQ,IAAI,EAAE;cAA3G,CACE,qBAAC,MAAM,SAAP;KAAe,UAAS;KAAI,MAAM,OAAO,IAAI,GAAG;eAAhD,CACE,oBAAC,MAAM,OAAP,EAAA,UAAc,MAAmB,CAAA,GACjC,oBAAC,MAAM,aAAP,EAAA,UAAoB,QAA2B,CAAA,CAClC;QACd,CAAC,CAAC,cAAc,oBAAC,0BAAD;KAA0B,QAAQ;KAAY,cAAc;IAAqB,CAAA,CAC/F;;GACJ,CAAC,CAAC,eAAe,oBAAC,yBAAD;IAAyB,cAAc;IAA6B;GAAU,CAAA;EACtF;;AAEhB;AAEA,kBAAkB,cAAc"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@bitrise/bitkit-v2",
3
3
  "private": false,
4
- "version": "0.3.280-beta.1864",
4
+ "version": "0.3.280-beta.1866",
5
5
  "description": "Bitrise Design System Components built with Chakra UI V3",
6
6
  "keywords": [
7
7
  "react",