@os-design/website 1.0.158 → 1.0.160

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.
@@ -4,17 +4,11 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports["default"] = void 0;
7
-
8
7
  var _styled = _interopRequireDefault(require("@emotion/styled"));
9
-
10
8
  var _core = require("@os-design/core");
11
-
12
9
  var _templateObject;
13
-
14
10
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
15
-
16
11
  function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
17
-
18
12
  /**
19
13
  * The page content of the website page.
20
14
  */
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["PageContent","styled","BasePageContent"],"sources":["../../../src/PageContent/index.tsx"],"sourcesContent":["import styled from '@emotion/styled';\nimport {\n PageContent as BasePageContent,\n PageContentProps as BasePageContentProps,\n} from '@os-design/core';\n\nexport type PageContentProps = BasePageContentProps;\n\n/**\n * The page content of the website page.\n */\nconst PageContent = styled(BasePageContent)`\n padding: 0 !important;\n`;\n\nexport default PageContent;\n"],"mappings":";;;;;;;AAAA;;AACA;;;;;;;;AAOA;AACA;AACA;AACA,IAAMA,WAAW,GAAG,IAAAC,kBAAA,EAAOC,iBAAP,CAAH,iGAAjB;eAIeF,W"}
1
+ {"version":3,"file":"index.js","names":["PageContent","styled","BasePageContent"],"sources":["../../../src/PageContent/index.tsx"],"sourcesContent":["import styled from '@emotion/styled';\nimport {\n PageContent as BasePageContent,\n PageContentProps as BasePageContentProps,\n} from '@os-design/core';\n\nexport type PageContentProps = BasePageContentProps;\n\n/**\n * The page content of the website page.\n */\nconst PageContent = styled(BasePageContent)`\n padding: 0 !important;\n`;\n\nexport default PageContent;\n"],"mappings":";;;;;;AAAA;AACA;AAGyB;AAAA;AAAA;AAIzB;AACA;AACA;AACA,IAAMA,WAAW,GAAG,IAAAC,kBAAM,EAACC,iBAAe,CAAC,iGAE1C;AAAC,eAEaF,WAAW;AAAA"}
@@ -1,53 +1,32 @@
1
1
  "use strict";
2
2
 
3
3
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
8
7
  exports["default"] = void 0;
9
-
10
8
  var _react = _interopRequireWildcard(require("react"));
11
-
12
9
  var _styles = require("@os-design/styles");
13
-
14
10
  var _utils = require("@os-design/utils");
15
-
16
11
  var _styled = _interopRequireDefault(require("@emotion/styled"));
17
-
18
12
  var _theming = require("@os-design/theming");
19
-
20
13
  var _core = require("@os-design/core");
21
-
22
14
  var _react2 = require("@emotion/react");
23
-
24
15
  var _media = require("@os-design/media");
25
-
26
16
  var _excluded = ["bgUrl", "bgProps", "limitedWidth", "centered", "size", "children"],
27
- _excluded2 = ["className"];
28
-
17
+ _excluded2 = ["className"];
29
18
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5;
30
-
31
19
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
32
-
33
20
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
34
-
35
21
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
36
-
37
22
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
38
-
39
23
  function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
40
-
41
24
  function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
42
-
43
25
  function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
44
-
45
26
  var BG_IMAGE_CLASS_NAME = 'section-bg-image';
46
-
47
27
  var hasBgStyles = function hasBgStyles(p) {
48
28
  return p.hasBg && (0, _react2.css)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n & > *:not(.", ") {\n z-index: 1;\n }\n "])), BG_IMAGE_CLASS_NAME);
49
29
  };
50
-
51
30
  var Container = (0, _styled["default"])('section', (0, _utils.omitEmotionProps)('hasBg', 'size'))(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n position: relative;\n\n display: flex;\n flex-direction: column;\n align-items: center;\n\n padding: ", "em\n ", "em;\n ", " {\n padding: ", "em\n ", "em;\n }\n\n color: ", ";\n\n ", ";\n ", ";\n"])), function (p) {
52
31
  return p.theme.sectionPaddingVertical;
53
32
  }, function (p) {
@@ -62,38 +41,33 @@ var Container = (0, _styled["default"])('section', (0, _utils.omitEmotionProps)(
62
41
  var BackgroundImage = (0, _styled["default"])(_core.Image)(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n // Reset image styles\n border-radius: 0;\n\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n filter: brightness(", "%);\n"])), function (p) {
63
42
  return p.theme.sectionBgImageBrightness;
64
43
  });
65
-
66
44
  var centeredStyles = function centeredStyles(p) {
67
45
  return p.centered && (0, _react2.css)(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n align-items: center;\n text-align: center;\n "])));
68
46
  };
69
-
70
47
  var LimitedWidth = (0, _styled["default"])('div', (0, _utils.omitEmotionProps)('centered'))(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n width: 100%;\n max-width: ", "em;\n ", ";\n"])), function (p) {
71
48
  return p.theme.sectionMaxWidth;
72
49
  }, centeredStyles);
50
+
73
51
  /**
74
52
  * The base section for the content.
75
53
  */
76
-
77
54
  var Section = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
78
55
  var bgUrl = _ref.bgUrl,
79
- _ref$bgProps = _ref.bgProps,
80
- bgProps = _ref$bgProps === void 0 ? {
81
- defaultSize: 1024
82
- } : _ref$bgProps,
83
- _ref$limitedWidth = _ref.limitedWidth,
84
- limitedWidth = _ref$limitedWidth === void 0 ? false : _ref$limitedWidth,
85
- _ref$centered = _ref.centered,
86
- centered = _ref$centered === void 0 ? false : _ref$centered,
87
- size = _ref.size,
88
- children = _ref.children,
89
- rest = _objectWithoutProperties(_ref, _excluded);
90
-
56
+ _ref$bgProps = _ref.bgProps,
57
+ bgProps = _ref$bgProps === void 0 ? {
58
+ defaultSize: 1024
59
+ } : _ref$bgProps,
60
+ _ref$limitedWidth = _ref.limitedWidth,
61
+ limitedWidth = _ref$limitedWidth === void 0 ? false : _ref$limitedWidth,
62
+ _ref$centered = _ref.centered,
63
+ centered = _ref$centered === void 0 ? false : _ref$centered,
64
+ size = _ref.size,
65
+ children = _ref.children,
66
+ rest = _objectWithoutProperties(_ref, _excluded);
91
67
  var bgClassName = bgProps.className,
92
- restBgProps = _objectWithoutProperties(bgProps, _excluded2);
93
-
68
+ restBgProps = _objectWithoutProperties(bgProps, _excluded2);
94
69
  var _useTheme = (0, _theming.useTheme)(),
95
- overrides = _useTheme.overrides;
96
-
70
+ overrides = _useTheme.overrides;
97
71
  var section = /*#__PURE__*/_react["default"].createElement(Container, _extends({
98
72
  hasBg: !!bgUrl,
99
73
  size: size
@@ -108,7 +82,6 @@ var Section = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
108
82
  return i;
109
83
  }).join(' ')
110
84
  }, restBgProps)));
111
-
112
85
  if (!bgUrl) return section;
113
86
  return /*#__PURE__*/_react["default"].createElement(_theming.ThemeOverrider, {
114
87
  activeTheme: "dark",
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["BG_IMAGE_CLASS_NAME","hasBgStyles","p","hasBg","css","Container","styled","omitEmotionProps","theme","sectionPaddingVertical","sectionPaddingHorizontal","m","min","sm","clr","colorText","sizeStyles","BackgroundImage","Image","sectionBgImageBrightness","centeredStyles","centered","LimitedWidth","sectionMaxWidth","Section","forwardRef","ref","bgUrl","bgProps","defaultSize","limitedWidth","size","children","rest","bgClassName","className","restBgProps","useTheme","overrides","section","filter","i","join","displayName"],"sources":["../../../src/Section/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { sizeStyles, WithSize } from '@os-design/styles';\nimport { omitEmotionProps } from '@os-design/utils';\nimport styled from '@emotion/styled';\nimport { clr, ThemeOverrider, useTheme } from '@os-design/theming';\nimport { Image, ImageProps } from '@os-design/core';\nimport { css } from '@emotion/react';\nimport { m } from '@os-design/media';\n\ntype JsxSectionProps = Omit<JSX.IntrinsicElements['section'], 'ref'>;\nexport interface SectionProps extends JsxSectionProps, WithSize {\n /**\n * The URL of the background image.\n * @default undefined\n */\n bgUrl?: string;\n /**\n * Props of the background image.\n * @default undefined\n */\n bgProps?: Omit<ImageProps, 'url' | 'cover'>;\n /**\n * Whether the content has a limited width.\n * @default false\n */\n limitedWidth?: boolean;\n /**\n * Whether the content is centered.\n * @default false\n */\n centered?: boolean;\n}\n\nconst BG_IMAGE_CLASS_NAME = 'section-bg-image';\n\nconst hasBgStyles = (p) =>\n p.hasBg &&\n css`\n & > *:not(.${BG_IMAGE_CLASS_NAME}) {\n z-index: 1;\n }\n `;\n\ninterface ContainerProps extends WithSize {\n hasBg: boolean;\n}\nconst Container = styled(\n 'section',\n omitEmotionProps('hasBg', 'size')\n)<ContainerProps>`\n position: relative;\n\n display: flex;\n flex-direction: column;\n align-items: center;\n\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[0]}em;\n ${m.min.sm} {\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[1]}em;\n }\n\n color: ${(p) => clr(p.theme.colorText)};\n\n ${hasBgStyles};\n ${sizeStyles};\n`;\n\nconst BackgroundImage = styled(Image)`\n // Reset image styles\n border-radius: 0;\n\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n filter: brightness(${(p) => p.theme.sectionBgImageBrightness}%);\n`;\n\nconst centeredStyles = (p) =>\n p.centered &&\n css`\n display: flex;\n flex-direction: column;\n align-items: center;\n text-align: center;\n `;\n\ninterface LimitedWidthProps {\n centered: boolean;\n}\nconst LimitedWidth = styled(\n 'div',\n omitEmotionProps('centered')\n)<LimitedWidthProps>`\n width: 100%;\n max-width: ${(p) => p.theme.sectionMaxWidth}em;\n ${centeredStyles};\n`;\n\n/**\n * The base section for the content.\n */\nconst Section = forwardRef<HTMLElement, SectionProps>(\n (\n {\n bgUrl,\n bgProps = { defaultSize: 1024 },\n limitedWidth = false,\n centered = false,\n size,\n children,\n ...rest\n },\n ref\n ) => {\n const { className: bgClassName, ...restBgProps } = bgProps;\n const { overrides } = useTheme();\n\n const section = (\n <Container hasBg={!!bgUrl} size={size} {...rest} ref={ref}>\n {limitedWidth ? (\n <LimitedWidth centered={centered}>{children}</LimitedWidth>\n ) : (\n children\n )}\n {bgUrl && (\n <BackgroundImage\n url={bgUrl}\n cover\n className={[bgClassName, BG_IMAGE_CLASS_NAME]\n .filter((i) => i)\n .join(' ')}\n {...restBgProps}\n />\n )}\n </Container>\n );\n\n if (!bgUrl) return section;\n return (\n <ThemeOverrider activeTheme='dark' overrides={overrides}>\n {section}\n </ThemeOverrider>\n );\n }\n);\n\nSection.displayName = 'Section';\n\nexport default Section;\n"],"mappings":";;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;;;;;;;;;;;;AA0BA,IAAMA,mBAAmB,GAAG,kBAA5B;;AAEA,IAAMC,WAAW,GAAG,SAAdA,WAAc,CAACC,CAAD;EAAA,OAClBA,CAAC,CAACC,KAAF,QACAC,WADA,6HAEeJ,mBAFf,CADkB;AAAA,CAApB;;AAWA,IAAMK,SAAS,GAAG,IAAAC,kBAAA,EAChB,SADgB,EAEhB,IAAAC,uBAAA,EAAiB,OAAjB,EAA0B,MAA1B,CAFgB,CAAH,mSAUF,UAACL,CAAD;EAAA,OAAOA,CAAC,CAACM,KAAF,CAAQC,sBAAf;AAAA,CAVE,EAWT,UAACP,CAAD;EAAA,OAAOA,CAAC,CAACM,KAAF,CAAQE,wBAAR,CAAiC,CAAjC,CAAP;AAAA,CAXS,EAYXC,QAAA,CAAEC,GAAF,CAAMC,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AAnD;;EACA,gBAAsB,IAAAS,iBAAA,GAAtB;EAAA,IAAQC,SAAR,aAAQA,SAAR;;EAEA,IAAMC,OAAO,gBACX,gCAAC,SAAD;IAAW,KAAK,EAAE,CAAC,CAACZ,KAApB;IAA2B,IAAI,EAAEI;EAAjC,GAA2CE,IAA3C;IAAiD,GAAG,EAAEP;EAAtD,IACGI,YAAY,gBACX,gCAAC,YAAD;IAAc,QAAQ,EAAET;EAAxB,GAAmCW,QAAnC,CADW,GAGXA,QAJJ,EAMGL,KAAK,iBACJ,gCAAC,eAAD;IACE,GAAG,EAAEA,KADP;IAEE,KAAK,MAFP;IAGE,SAAS,EAAE,CAACO,WAAD,EAAclC,mBAAd,EACRwC,MADQ,CACD,UAACC,CAAD;MAAA,OAAOA,CAAP;IAAA,CADC,EAERC,IAFQ,CAEH,GAFG;EAHb,GAMMN,WANN,EAPJ,CADF;;EAoBA,IAAI,CAACT,KAAL,EAAY,OAAOY,OAAP;EACZ,oBACE,gCAAC,uBAAD;IAAgB,WAAW,EAAC,MAA5B;IAAmC,SAAS,EAAED;EAA9C,GACGC,OADH,CADF;AAKD,CA1Ca,CAAhB;AA6CAf,OAAO,CAACmB,WAAR,GAAsB,SAAtB;eAEenB,O"}
1
+ {"version":3,"file":"index.js","names":["BG_IMAGE_CLASS_NAME","hasBgStyles","p","hasBg","css","Container","styled","omitEmotionProps","theme","sectionPaddingVertical","sectionPaddingHorizontal","m","min","sm","clr","colorText","sizeStyles","BackgroundImage","Image","sectionBgImageBrightness","centeredStyles","centered","LimitedWidth","sectionMaxWidth","Section","forwardRef","ref","bgUrl","bgProps","defaultSize","limitedWidth","size","children","rest","bgClassName","className","restBgProps","useTheme","overrides","section","filter","i","join","displayName"],"sources":["../../../src/Section/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { sizeStyles, WithSize } from '@os-design/styles';\nimport { omitEmotionProps } from '@os-design/utils';\nimport styled from '@emotion/styled';\nimport { clr, ThemeOverrider, useTheme } from '@os-design/theming';\nimport { Image, ImageProps } from '@os-design/core';\nimport { css } from '@emotion/react';\nimport { m } from '@os-design/media';\n\ntype JsxSectionProps = Omit<JSX.IntrinsicElements['section'], 'ref'>;\nexport interface SectionProps extends JsxSectionProps, WithSize {\n /**\n * The URL of the background image.\n * @default undefined\n */\n bgUrl?: string;\n /**\n * Props of the background image.\n * @default undefined\n */\n bgProps?: Omit<ImageProps, 'url' | 'cover'>;\n /**\n * Whether the content has a limited width.\n * @default false\n */\n limitedWidth?: boolean;\n /**\n * Whether the content is centered.\n * @default false\n */\n centered?: boolean;\n}\n\nconst BG_IMAGE_CLASS_NAME = 'section-bg-image';\n\nconst hasBgStyles = (p) =>\n p.hasBg &&\n css`\n & > *:not(.${BG_IMAGE_CLASS_NAME}) {\n z-index: 1;\n }\n `;\n\ninterface ContainerProps extends WithSize {\n hasBg: boolean;\n}\nconst Container = styled(\n 'section',\n omitEmotionProps('hasBg', 'size')\n)<ContainerProps>`\n position: relative;\n\n display: flex;\n flex-direction: column;\n align-items: center;\n\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[0]}em;\n ${m.min.sm} {\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[1]}em;\n }\n\n color: ${(p) => clr(p.theme.colorText)};\n\n ${hasBgStyles};\n ${sizeStyles};\n`;\n\nconst BackgroundImage = styled(Image)`\n // Reset image styles\n border-radius: 0;\n\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n filter: brightness(${(p) => p.theme.sectionBgImageBrightness}%);\n`;\n\nconst centeredStyles = (p) =>\n p.centered &&\n css`\n display: flex;\n flex-direction: column;\n align-items: center;\n text-align: center;\n `;\n\ninterface LimitedWidthProps {\n centered: boolean;\n}\nconst LimitedWidth = styled(\n 'div',\n omitEmotionProps('centered')\n)<LimitedWidthProps>`\n width: 100%;\n max-width: ${(p) => p.theme.sectionMaxWidth}em;\n ${centeredStyles};\n`;\n\n/**\n * The base section for the content.\n */\nconst Section = forwardRef<HTMLElement, SectionProps>(\n (\n {\n bgUrl,\n bgProps = { defaultSize: 1024 },\n limitedWidth = false,\n centered = false,\n size,\n children,\n ...rest\n },\n ref\n ) => {\n const { className: bgClassName, ...restBgProps } = bgProps;\n const { overrides } = useTheme();\n\n const section = (\n <Container hasBg={!!bgUrl} size={size} {...rest} ref={ref}>\n {limitedWidth ? (\n <LimitedWidth centered={centered}>{children}</LimitedWidth>\n ) : (\n children\n )}\n {bgUrl && (\n <BackgroundImage\n url={bgUrl}\n cover\n className={[bgClassName, BG_IMAGE_CLASS_NAME]\n .filter((i) => i)\n .join(' ')}\n {...restBgProps}\n />\n )}\n </Container>\n );\n\n if (!bgUrl) return section;\n return (\n <ThemeOverrider activeTheme='dark' overrides={overrides}>\n {section}\n </ThemeOverrider>\n );\n }\n);\n\nSection.displayName = 'Section';\n\nexport default Section;\n"],"mappings":";;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAAqC;EAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA0BrC,IAAMA,mBAAmB,GAAG,kBAAkB;AAE9C,IAAMC,WAAW,GAAG,SAAdA,WAAW,CAAIC,CAAC;EAAA,OACpBA,CAAC,CAACC,KAAK,QACPC,WAAG,6HACYJ,mBAAmB,CAGjC;AAAA;AAKH,IAAMK,SAAS,GAAG,IAAAC,kBAAM,EACtB,SAAS,EACT,IAAAC,uBAAgB,EAAC,OAAO,EAAE,MAAM,CAAC,CAClC,mSAOY,UAACL,CAAC;EAAA,OAAKA,CAAC,CAACM,KAAK,CAACC,sBAAsB;AAAA,GAC5C,UAACP,CAAC;EAAA,OAAKA,CAAC,CAACM,KAAK,CAACE,wBAAwB,CAAC,CAAC,CAAC;AAAA,GAC5CC,QAAC,CAACC,GAAG,CAACC,EAAE,EACG,UAACX,CAAC;EAAA,OAAKA,CAAC,CAACM,KAAK,CAACC,sBAAsB;A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AEI;EAAK,GAAKE,IAAI;IAAE,GAAG,EAAEP;EAAI,IACvDI,YAAY,gBACX,gCAAC,YAAY;IAAC,QAAQ,EAAET;EAAS,GAAEW,QAAQ,CAAgB,GAE3DA,QACD,EACAL,KAAK,iBACJ,gCAAC,eAAe;IACd,GAAG,EAAEA,KAAM;IACX,KAAK;IACL,SAAS,EAAE,CAACO,WAAW,EAAElC,mBAAmB,CAAC,CAC1CwC,MAAM,CAAC,UAACC,CAAC;MAAA,OAAKA,CAAC;IAAA,EAAC,CAChBC,IAAI,CAAC,GAAG;EAAE,GACTN,WAAW,EAElB,CAEJ;EAED,IAAI,CAACT,KAAK,EAAE,OAAOY,OAAO;EAC1B,oBACE,gCAAC,uBAAc;IAAC,WAAW,EAAC,MAAM;IAAC,SAAS,EAAED;EAAU,GACrDC,OAAO,CACO;AAErB,CAAC,CACF;AAEDf,OAAO,CAACmB,WAAW,GAAG,SAAS;AAAC,eAEjBnB,OAAO;AAAA"}
@@ -1,74 +1,49 @@
1
1
  "use strict";
2
2
 
3
3
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
8
7
  exports["default"] = void 0;
9
-
10
8
  var _react = _interopRequireWildcard(require("react"));
11
-
12
9
  var _styled = _interopRequireDefault(require("@emotion/styled"));
13
-
14
10
  var _react2 = require("@emotion/react");
15
-
16
11
  var _utils = require("@os-design/utils");
17
-
18
12
  var _media = require("@os-design/media");
19
-
20
13
  var _theming = require("@os-design/theming");
21
-
22
14
  var _Section = _interopRequireDefault(require("../Section"));
23
-
24
15
  var _excluded = ["media", "children"];
25
-
26
16
  var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7;
27
-
28
17
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
29
-
30
18
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
31
-
32
19
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
33
-
34
20
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
35
-
36
21
  function _objectWithoutProperties(source, excluded) { if (source == null) return {}; var target = _objectWithoutPropertiesLoose(source, excluded); var key, i; if (Object.getOwnPropertySymbols) { var sourceSymbolKeys = Object.getOwnPropertySymbols(source); for (i = 0; i < sourceSymbolKeys.length; i++) { key = sourceSymbolKeys[i]; if (excluded.indexOf(key) >= 0) continue; if (!Object.prototype.propertyIsEnumerable.call(source, key)) continue; target[key] = source[key]; } } return target; }
37
-
38
22
  function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
39
-
40
23
  function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
41
-
42
24
  var containerHasMediaStyles = function containerHasMediaStyles(p) {
43
25
  return p.hasMedia && (0, _react2.css)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: grid;\n\n grid-template-columns: 1fr;\n grid-template-rows: auto auto;\n grid-template-areas: 'content' 'media';\n grid-row-gap: ", "em;\n\n ", " {\n grid-template-columns:\n minmax(\n ", "%,\n ", "em\n )\n ", "%;\n grid-template-rows: 1fr;\n grid-template-areas: 'content media';\n grid-column-gap: ", "%;\n padding-right: ", "%;\n }\n "])), p.theme.sectionFeatureRowGap, _media.m.min.md, 100 - p.theme.sectionFeatureMediaWidthPercent, p.theme.sectionFeatureContentMaxWidth, p.theme.sectionFeatureMediaWidthPercent, p.theme.sectionFeatureColumnGapPercent, p.theme.sectionFeatureColumnGapPercent * 2);
44
26
  };
45
-
46
27
  var containerNotHasMediaStyles = function containerNotHasMediaStyles(p) {
47
28
  return !p.hasMedia && (0, _react2.css)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n max-width: ", "em;\n "])), p.theme.sectionFeatureContentMaxWidth);
48
29
  };
49
-
50
30
  var Container = (0, _styled["default"])('div', (0, _utils.omitEmotionProps)('hasMedia'))(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n color: ", ";\n ", ";\n ", ";\n"])), function (p) {
51
31
  return (0, _theming.clr)(p.theme.colorText);
52
32
  }, containerHasMediaStyles, containerNotHasMediaStyles);
53
-
54
33
  var Content = _styled["default"].div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n grid-area: content;\n align-self: center;\n"])));
55
-
56
34
  var Media = _styled["default"].div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n grid-area: media;\n align-self: center;\n"])));
57
-
58
35
  var sectionHasMediaStyles = function sectionHasMediaStyles(p) {
59
36
  return p.hasMedia && (0, _react2.css)(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n ", " {\n &:nth-of-type(even) {\n & > div {\n grid-template-areas: 'media content';\n grid-template-columns: ", "% minmax(\n ", "%,\n ", "em\n );\n }\n }\n }\n "])), _media.m.min.md, p.theme.sectionFeatureMediaWidthPercent, 100 - p.theme.sectionFeatureMediaWidthPercent, p.theme.sectionFeatureContentMaxWidth);
60
37
  };
61
-
62
38
  var StyledSection = (0, _styled["default"])(_Section["default"], (0, _utils.omitEmotionProps)('hasMedia'))(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n ", ";\n"])), sectionHasMediaStyles);
39
+
63
40
  /**
64
41
  * The section for describing an app feature.
65
42
  */
66
-
67
43
  var SectionFeature = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
68
44
  var media = _ref.media,
69
- children = _ref.children,
70
- rest = _objectWithoutProperties(_ref, _excluded);
71
-
45
+ children = _ref.children,
46
+ rest = _objectWithoutProperties(_ref, _excluded);
72
47
  return /*#__PURE__*/_react["default"].createElement(StyledSection, _extends({
73
48
  hasMedia: !!media
74
49
  }, rest, {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["containerHasMediaStyles","p","hasMedia","css","theme","sectionFeatureRowGap","m","min","md","sectionFeatureMediaWidthPercent","sectionFeatureContentMaxWidth","sectionFeatureColumnGapPercent","containerNotHasMediaStyles","Container","styled","omitEmotionProps","clr","colorText","Content","div","Media","sectionHasMediaStyles","StyledSection","Section","SectionFeature","forwardRef","ref","media","children","rest","displayName"],"sources":["../../../src/SectionFeature/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport styled from '@emotion/styled';\nimport { css } from '@emotion/react';\nimport { omitEmotionProps } from '@os-design/utils';\nimport { m } from '@os-design/media';\nimport { clr } from '@os-design/theming';\nimport Section, { SectionProps } from '../Section';\n\nexport interface SectionFeatureProps extends SectionProps {\n /**\n * The media component. For example, an image.\n * @default undefined\n */\n media?: React.ReactElement;\n}\n\nconst containerHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n display: grid;\n\n grid-template-columns: 1fr;\n grid-template-rows: auto auto;\n grid-template-areas: 'content' 'media';\n grid-row-gap: ${p.theme.sectionFeatureRowGap}em;\n\n ${m.min.md} {\n grid-template-columns:\n minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n )\n ${p.theme.sectionFeatureMediaWidthPercent}%;\n grid-template-rows: 1fr;\n grid-template-areas: 'content media';\n grid-column-gap: ${p.theme.sectionFeatureColumnGapPercent}%;\n padding-right: ${p.theme.sectionFeatureColumnGapPercent * 2}%;\n }\n `;\n\nconst containerNotHasMediaStyles = (p) =>\n !p.hasMedia &&\n css`\n max-width: ${p.theme.sectionFeatureContentMaxWidth}em;\n `;\n\ninterface ContainerProps {\n hasMedia: boolean;\n}\nconst Container = styled('div', omitEmotionProps('hasMedia'))<ContainerProps>`\n color: ${(p) => clr(p.theme.colorText)};\n ${containerHasMediaStyles};\n ${containerNotHasMediaStyles};\n`;\n\nconst Content = styled.div`\n grid-area: content;\n align-self: center;\n`;\n\nconst Media = styled.div`\n grid-area: media;\n align-self: center;\n`;\n\nconst sectionHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n ${m.min.md} {\n &:nth-of-type(even) {\n & > div {\n grid-template-areas: 'media content';\n grid-template-columns: ${p.theme.sectionFeatureMediaWidthPercent}% minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n );\n }\n }\n }\n `;\n\ninterface StyledSectionProps {\n hasMedia: boolean;\n}\nconst StyledSection = styled(\n Section,\n omitEmotionProps('hasMedia')\n)<StyledSectionProps>`\n ${sectionHasMediaStyles};\n`;\n\n/**\n * The section for describing an app feature.\n */\nconst SectionFeature = forwardRef<HTMLElement, SectionFeatureProps>(\n ({ media, children, ...rest }, ref) => (\n <StyledSection hasMedia={!!media} {...rest} ref={ref}>\n <Container hasMedia={!!media}>\n <Content>{children}</Content>\n {media && <Media>{media}</Media>}\n </Container>\n </StyledSection>\n )\n);\n\nSectionFeature.displayName = 'SectionFeature';\n\nexport default SectionFeature;\n"],"mappings":";;;;;;;;;AAAA;;AACA;;AACA;;AACA;;AACA;;AACA;;AACA;;;;;;;;;;;;;;;;;;;;AAUA,IAAMA,uBAAuB,GAAG,SAA1BA,uBAA0B,CAACC,CAAD;EAAA,OAC9BA,CAAC,CAACC,QAAF,QACAC,WADA,0fAOkBF,CAAC,CAACG,KAAF,CAAQC,oBAP1B,EASIC,QAAA,CAAEC,GAAF,CAAMC,EATV,EAYU,MAAMP,CAAC,CAACG,KAAF,CAAQK,+BAZxB,EAaUR,CAAC,CAACG,KAAF,CAAQM,6BAblB,EAeQT,CAAC,CAACG,KAAF,CAAQK,+BAfhB,EAkBuBR,CAAC,CAACG,KAAF,CAAQO,8BAlB/B,EAmBqBV,CAAC,CAACG,KAAF,CAAQO,8BAAR,GAAyC,CAnB9D,CAD8B;AAAA,CAAhC;;AAwBA,IAAMC,0BAA0B,GAAG,SAA7BA,0BAA6B,CAACX,CAAD;EAAA,OACjC,CAACA,CAAC,CAACC,QAAH,QACAC,WADA,qGAEeF,CAAC,CAACG,KAAF,CAAQM,6BAFvB,CADiC;AAAA,CAAnC;;AASA,IAAMG,SAAS,GAAG,IAAAC,kBAAA,EAAO,KAAP,EAAc,IAAAC,uBAAA,EAAiB,UAAjB,CAAd,CAAH,4GACJ,UAACd,CAAD;EAAA,OAAO,IAAAe,YAAA,EAAIf,CAAC,CAACG,KAAF,CAAQa,SAAZ,CAAP;AAAA,CADI,EAEXjB,uBAFW,EAGXY,0BAHW,CAAf;;AAMA,IAAMM,OAAO,GAAGJ,kBAAA,CAAOK,GAAV,uHAAb;;AAKA,IAAMC,KAAK,GAAGN,kBAAA,CAAOK,GAAV,qHAAX;;AAKA,IAAME,qBAAqB,GAAG,SAAxBA,qBAAwB,CAACpB,CAAD;EAAA,OAC5BA,CAAC,CAACC,QAAF,QACAC,WADA,iUAEIG,QAAA,CAAEC,GAAF,CAAMC,EAFV,EAMiCP,CAAC,CAACG,KAAF,CAAQK,+BANzC,EAOc,MAAMR,CAAC,CAACG,KAAF,CAAQK,+BAP5B,EAQcR,CAAC,CAACG,KAAF,CAAQM,6BARtB,CAD4B;AAAA,CAA9B;;AAmBA,IAAMY,aAAa,GAAG,IAAAR,kBAAA,EACpBS,mBADoB,EAEpB,IAAAR,uBAAA,EAAiB,UAAjB,CAFoB,CAAH,mFAIfM,qBAJe,CAAnB;AAOA;AACA;AACA;;AACA,IAAMG,cAAc,gBAAG,IAAAC,iBAAA,EACrB,gBAA+BC,GAA/B;EAAA,IAAGC,KAAH,QAAGA,KAAH;EAAA,IAAUC,QAAV,QAAUA,QAAV;EAAA,IAAuBC,IAAvB;;EAAA,oBACE,gCAAC,aAAD;IAAe,QAAQ,EAAE,CAAC,CAACF;EAA3B,GAAsCE,IAAtC;IAA4C,GAAG,EAAEH;EAAjD,iBACE,gCAAC,SAAD;IAAW,QAAQ,EAAE,CAAC,CAACC;EAAvB,gBACE,gCAAC,OAAD,QAAUC,QAAV,CADF,EAEGD,KAAK,iBAAI,gCAAC,KAAD,QAAQA,KAAR,CAFZ,CADF,CADF;AAAA,CADqB,CAAvB;AAWAH,cAAc,CAACM,WAAf,GAA6B,gBAA7B;eAEeN,c"}
1
+ {"version":3,"file":"index.js","names":["containerHasMediaStyles","p","hasMedia","css","theme","sectionFeatureRowGap","m","min","md","sectionFeatureMediaWidthPercent","sectionFeatureContentMaxWidth","sectionFeatureColumnGapPercent","containerNotHasMediaStyles","Container","styled","omitEmotionProps","clr","colorText","Content","div","Media","sectionHasMediaStyles","StyledSection","Section","SectionFeature","forwardRef","ref","media","children","rest","displayName"],"sources":["../../../src/SectionFeature/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport styled from '@emotion/styled';\nimport { css } from '@emotion/react';\nimport { omitEmotionProps } from '@os-design/utils';\nimport { m } from '@os-design/media';\nimport { clr } from '@os-design/theming';\nimport Section, { SectionProps } from '../Section';\n\nexport interface SectionFeatureProps extends SectionProps {\n /**\n * The media component. For example, an image.\n * @default undefined\n */\n media?: React.ReactElement;\n}\n\nconst containerHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n display: grid;\n\n grid-template-columns: 1fr;\n grid-template-rows: auto auto;\n grid-template-areas: 'content' 'media';\n grid-row-gap: ${p.theme.sectionFeatureRowGap}em;\n\n ${m.min.md} {\n grid-template-columns:\n minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n )\n ${p.theme.sectionFeatureMediaWidthPercent}%;\n grid-template-rows: 1fr;\n grid-template-areas: 'content media';\n grid-column-gap: ${p.theme.sectionFeatureColumnGapPercent}%;\n padding-right: ${p.theme.sectionFeatureColumnGapPercent * 2}%;\n }\n `;\n\nconst containerNotHasMediaStyles = (p) =>\n !p.hasMedia &&\n css`\n max-width: ${p.theme.sectionFeatureContentMaxWidth}em;\n `;\n\ninterface ContainerProps {\n hasMedia: boolean;\n}\nconst Container = styled('div', omitEmotionProps('hasMedia'))<ContainerProps>`\n color: ${(p) => clr(p.theme.colorText)};\n ${containerHasMediaStyles};\n ${containerNotHasMediaStyles};\n`;\n\nconst Content = styled.div`\n grid-area: content;\n align-self: center;\n`;\n\nconst Media = styled.div`\n grid-area: media;\n align-self: center;\n`;\n\nconst sectionHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n ${m.min.md} {\n &:nth-of-type(even) {\n & > div {\n grid-template-areas: 'media content';\n grid-template-columns: ${p.theme.sectionFeatureMediaWidthPercent}% minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n );\n }\n }\n }\n `;\n\ninterface StyledSectionProps {\n hasMedia: boolean;\n}\nconst StyledSection = styled(\n Section,\n omitEmotionProps('hasMedia')\n)<StyledSectionProps>`\n ${sectionHasMediaStyles};\n`;\n\n/**\n * The section for describing an app feature.\n */\nconst SectionFeature = forwardRef<HTMLElement, SectionFeatureProps>(\n ({ media, children, ...rest }, ref) => (\n <StyledSection hasMedia={!!media} {...rest} ref={ref}>\n <Container hasMedia={!!media}>\n <Content>{children}</Content>\n {media && <Media>{media}</Media>}\n </Container>\n </StyledSection>\n )\n);\n\nSectionFeature.displayName = 'SectionFeature';\n\nexport default SectionFeature;\n"],"mappings":";;;;;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AAAmD;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAUnD,IAAMA,uBAAuB,GAAG,SAA1BA,uBAAuB,CAAIC,CAAC;EAAA,OAChCA,CAAC,CAACC,QAAQ,QACVC,WAAG,0fAMeF,CAAC,CAACG,KAAK,CAACC,oBAAoB,EAE1CC,QAAC,CAACC,GAAG,CAACC,EAAE,EAGF,GAAG,GAAGP,CAAC,CAACG,KAAK,CAACK,+BAA+B,EAC7CR,CAAC,CAACG,KAAK,CAACM,6BAA6B,EAEvCT,CAAC,CAACG,KAAK,CAACK,+BAA+B,EAGxBR,CAAC,CAACG,KAAK,CAACO,8BAA8B,EACxCV,CAAC,CAACG,KAAK,CAACO,8BAA8B,GAAG,CAAC,CAE9D;AAAA;AAEH,IAAMC,0BAA0B,GAAG,SAA7BA,0BAA0B,CAAIX,CAAC;EAAA,OACnC,CAACA,CAAC,CAACC,QAAQ,QACXC,WAAG,qGACYF,CAAC,CAACG,KAAK,CAACM,6BAA6B,CACnD;AAAA;AAKH,IAAMG,SAAS,GAAG,IAAAC,kBAAM,EAAC,KAAK,EAAE,IAAAC,uBAAgB,EAAC,UAAU,CAAC,CAAC,4GAClD,UAACd,CAAC;EAAA,OAAK,IAAAe,YAAG,EAACf,CAAC,CAACG,KAAK,CAACa,SAAS,CAAC;AAAA,GACpCjB,uBAAuB,EACvBY,0BAA0B,CAC7B;AAED,IAAMM,OAAO,GAAGJ,kBAAM,CAACK,GAAG,uHAGzB;AAED,IAAMC,KAAK,GAAGN,kBAAM,CAACK,GAAG,qHAGvB;AAED,IAAME,qBAAqB,GAAG,SAAxBA,qBAAqB,CAAIpB,CAAC;EAAA,OAC9BA,CAAC,CAACC,QAAQ,QACVC,WAAG,iUACCG,QAAC,CAACC,GAAG,CAACC,EAAE,EAIqBP,CAAC,CAACG,KAAK,CAACK,+BAA+B,EAC1D,GAAG,GAAGR,CAAC,CAACG,KAAK,CAACK,+BAA+B,EAC7CR,CAAC,CAACG,KAAK,CAACM,6BAA6B,CAKlD;AAAA;AAKH,IAAMY,aAAa,GAAG,IAAAR,kBAAM,EAC1BS,mBAAO,EACP,IAAAR,uBAAgB,EAAC,UAAU,CAAC,CAC7B,mFACGM,qBAAqB,CACxB;;AAED;AACA;AACA;AACA,IAAMG,cAAc,gBAAG,IAAAC,iBAAU,EAC/B,gBAA+BC,GAAG;EAAA,IAA/BC,KAAK,QAALA,KAAK;IAAEC,QAAQ,QAARA,QAAQ;IAAKC,IAAI;EAAA,oBACzB,gCAAC,aAAa;IAAC,QAAQ,EAAE,CAAC,CAACF;EAAM,GAAKE,IAAI;IAAE,GAAG,EAAEH;EAAI,iBACnD,gCAAC,SAAS;IAAC,QAAQ,EAAE,CAAC,CAACC;EAAM,gBAC3B,gCAAC,OAAO,QAAEC,QAAQ,CAAW,EAC5BD,KAAK,iBAAI,gCAAC,KAAK,QAAEA,KAAK,CAAS,CACtB,CACE;AAAA,CACjB,CACF;AAEDH,cAAc,CAACM,WAAW,GAAG,gBAAgB;AAAC,eAE/BN,cAAc;AAAA"}
package/dist/cjs/index.js CHANGED
@@ -1,7 +1,6 @@
1
1
  "use strict";
2
2
 
3
3
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
4
-
5
4
  Object.defineProperty(exports, "__esModule", {
6
5
  value: true
7
6
  });
@@ -28,9 +27,7 @@ Object.defineProperty(exports, "SectionFeature", {
28
27
  return _SectionFeature["default"];
29
28
  }
30
29
  });
31
-
32
30
  var _PageContent = _interopRequireWildcard(require("./PageContent"));
33
-
34
31
  Object.keys(_PageContent).forEach(function (key) {
35
32
  if (key === "default" || key === "__esModule") return;
36
33
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -42,9 +39,7 @@ Object.keys(_PageContent).forEach(function (key) {
42
39
  }
43
40
  });
44
41
  });
45
-
46
42
  var _Section = _interopRequireWildcard(require("./Section"));
47
-
48
43
  Object.keys(_Section).forEach(function (key) {
49
44
  if (key === "default" || key === "__esModule") return;
50
45
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -56,9 +51,7 @@ Object.keys(_Section).forEach(function (key) {
56
51
  }
57
52
  });
58
53
  });
59
-
60
54
  var _SectionFeature = _interopRequireWildcard(require("./SectionFeature"));
61
-
62
55
  Object.keys(_SectionFeature).forEach(function (key) {
63
56
  if (key === "default" || key === "__esModule") return;
64
57
  if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
@@ -70,8 +63,6 @@ Object.keys(_SectionFeature).forEach(function (key) {
70
63
  }
71
64
  });
72
65
  });
73
-
74
66
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
75
-
76
67
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { "default": obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj["default"] = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
77
68
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":[],"sources":["../../src/index.ts"],"sourcesContent":["export { default as PageContent } from './PageContent';\nexport { default as Section } from './Section';\nexport { default as SectionFeature } from './SectionFeature';\n\nexport * from './PageContent';\nexport * from './Section';\nexport * from './SectionFeature';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;;AAIA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA;;AAHA;;AAIA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA;;AAHA;;AAIA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA"}
1
+ {"version":3,"file":"index.js","names":[],"sources":["../../src/index.ts"],"sourcesContent":["export { default as PageContent } from './PageContent';\nexport { default as Section } from './Section';\nexport { default as SectionFeature } from './SectionFeature';\n\nexport * from './PageContent';\nexport * from './Section';\nexport * from './SectionFeature';\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAIA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA;AAHA;AAIA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA;AAHA;AAIA;EAAA;EAAA;EAAA;EAAA;IAAA;IAAA;MAAA;IAAA;EAAA;AAAA;AAAiC;AAAA"}
@@ -1,6 +1,5 @@
1
1
  import styled from '@emotion/styled';
2
2
  import { PageContent as BasePageContent } from '@os-design/core';
3
-
4
3
  /**
5
4
  * The page content of the website page.
6
5
  */
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["styled","PageContent","BasePageContent"],"sources":["../../../src/PageContent/index.tsx"],"sourcesContent":["import styled from '@emotion/styled';\nimport {\n PageContent as BasePageContent,\n PageContentProps as BasePageContentProps,\n} from '@os-design/core';\n\nexport type PageContentProps = BasePageContentProps;\n\n/**\n * The page content of the website page.\n */\nconst PageContent = styled(BasePageContent)`\n padding: 0 !important;\n`;\n\nexport default PageContent;\n"],"mappings":"AAAA,OAAOA,MAAP,MAAmB,iBAAnB;AACA,SACEC,WAAW,IAAIC,eADjB,QAGO,iBAHP;;AAOA;AACA;AACA;AACA,MAAMD,WAAW,GAAGD,MAAM,CAACE,eAAD,CAAkB;AAC5C;AACA,CAFA;AAIA,eAAeD,WAAf"}
1
+ {"version":3,"file":"index.js","names":["styled","PageContent","BasePageContent"],"sources":["../../../src/PageContent/index.tsx"],"sourcesContent":["import styled from '@emotion/styled';\nimport {\n PageContent as BasePageContent,\n PageContentProps as BasePageContentProps,\n} from '@os-design/core';\n\nexport type PageContentProps = BasePageContentProps;\n\n/**\n * The page content of the website page.\n */\nconst PageContent = styled(BasePageContent)`\n padding: 0 !important;\n`;\n\nexport default PageContent;\n"],"mappings":"AAAA,OAAOA,MAAM,MAAM,iBAAiB;AACpC,SACEC,WAAW,IAAIC,eAAe,QAEzB,iBAAiB;AAIxB;AACA;AACA;AACA,MAAMD,WAAW,GAAGD,MAAM,CAACE,eAAe,CAAE;AAC5C;AACA,CAAC;AAED,eAAeD,WAAW"}
@@ -1,5 +1,4 @@
1
1
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
2
  import React, { forwardRef } from 'react';
4
3
  import { sizeStyles } from '@os-design/styles';
5
4
  import { omitEmotionProps } from '@os-design/utils';
@@ -9,13 +8,11 @@ import { Image } from '@os-design/core';
9
8
  import { css } from '@emotion/react';
10
9
  import { m } from '@os-design/media';
11
10
  const BG_IMAGE_CLASS_NAME = 'section-bg-image';
12
-
13
11
  const hasBgStyles = p => p.hasBg && css`
14
12
  & > *:not(.${BG_IMAGE_CLASS_NAME}) {
15
13
  z-index: 1;
16
14
  }
17
15
  `;
18
-
19
16
  const Container = styled('section', omitEmotionProps('hasBg', 'size'))`
20
17
  position: relative;
21
18
 
@@ -46,23 +43,21 @@ const BackgroundImage = styled(Image)`
46
43
  height: 100%;
47
44
  filter: brightness(${p => p.theme.sectionBgImageBrightness}%);
48
45
  `;
49
-
50
46
  const centeredStyles = p => p.centered && css`
51
47
  display: flex;
52
48
  flex-direction: column;
53
49
  align-items: center;
54
50
  text-align: center;
55
51
  `;
56
-
57
52
  const LimitedWidth = styled('div', omitEmotionProps('centered'))`
58
53
  width: 100%;
59
54
  max-width: ${p => p.theme.sectionMaxWidth}em;
60
55
  ${centeredStyles};
61
56
  `;
57
+
62
58
  /**
63
59
  * The base section for the content.
64
60
  */
65
-
66
61
  const Section = /*#__PURE__*/forwardRef(({
67
62
  bgUrl,
68
63
  bgProps = {
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["React","forwardRef","sizeStyles","omitEmotionProps","styled","clr","ThemeOverrider","useTheme","Image","css","m","BG_IMAGE_CLASS_NAME","hasBgStyles","p","hasBg","Container","theme","sectionPaddingVertical","sectionPaddingHorizontal","min","sm","colorText","BackgroundImage","sectionBgImageBrightness","centeredStyles","centered","LimitedWidth","sectionMaxWidth","Section","bgUrl","bgProps","defaultSize","limitedWidth","size","children","rest","ref","className","bgClassName","restBgProps","overrides","section","filter","i","join","displayName"],"sources":["../../../src/Section/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { sizeStyles, WithSize } from '@os-design/styles';\nimport { omitEmotionProps } from '@os-design/utils';\nimport styled from '@emotion/styled';\nimport { clr, ThemeOverrider, useTheme } from '@os-design/theming';\nimport { Image, ImageProps } from '@os-design/core';\nimport { css } from '@emotion/react';\nimport { m } from '@os-design/media';\n\ntype JsxSectionProps = Omit<JSX.IntrinsicElements['section'], 'ref'>;\nexport interface SectionProps extends JsxSectionProps, WithSize {\n /**\n * The URL of the background image.\n * @default undefined\n */\n bgUrl?: string;\n /**\n * Props of the background image.\n * @default undefined\n */\n bgProps?: Omit<ImageProps, 'url' | 'cover'>;\n /**\n * Whether the content has a limited width.\n * @default false\n */\n limitedWidth?: boolean;\n /**\n * Whether the content is centered.\n * @default false\n */\n centered?: boolean;\n}\n\nconst BG_IMAGE_CLASS_NAME = 'section-bg-image';\n\nconst hasBgStyles = (p) =>\n p.hasBg &&\n css`\n & > *:not(.${BG_IMAGE_CLASS_NAME}) {\n z-index: 1;\n }\n `;\n\ninterface ContainerProps extends WithSize {\n hasBg: boolean;\n}\nconst Container = styled(\n 'section',\n omitEmotionProps('hasBg', 'size')\n)<ContainerProps>`\n position: relative;\n\n display: flex;\n flex-direction: column;\n align-items: center;\n\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[0]}em;\n ${m.min.sm} {\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[1]}em;\n }\n\n color: ${(p) => clr(p.theme.colorText)};\n\n ${hasBgStyles};\n ${sizeStyles};\n`;\n\nconst BackgroundImage = styled(Image)`\n // Reset image styles\n border-radius: 0;\n\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n filter: brightness(${(p) => p.theme.sectionBgImageBrightness}%);\n`;\n\nconst centeredStyles = (p) =>\n p.centered &&\n css`\n display: flex;\n flex-direction: column;\n align-items: center;\n text-align: center;\n `;\n\ninterface LimitedWidthProps {\n centered: boolean;\n}\nconst LimitedWidth = styled(\n 'div',\n omitEmotionProps('centered')\n)<LimitedWidthProps>`\n width: 100%;\n max-width: ${(p) => p.theme.sectionMaxWidth}em;\n ${centeredStyles};\n`;\n\n/**\n * The base section for the content.\n */\nconst Section = forwardRef<HTMLElement, SectionProps>(\n (\n {\n bgUrl,\n bgProps = { defaultSize: 1024 },\n limitedWidth = false,\n centered = false,\n size,\n children,\n ...rest\n },\n ref\n ) => {\n const { className: bgClassName, ...restBgProps } = bgProps;\n const { overrides } = useTheme();\n\n const section = (\n <Container hasBg={!!bgUrl} size={size} {...rest} ref={ref}>\n {limitedWidth ? (\n <LimitedWidth centered={centered}>{children}</LimitedWidth>\n ) : (\n children\n )}\n {bgUrl && (\n <BackgroundImage\n url={bgUrl}\n cover\n className={[bgClassName, BG_IMAGE_CLASS_NAME]\n .filter((i) => i)\n .join(' ')}\n {...restBgProps}\n />\n )}\n </Container>\n );\n\n if (!bgUrl) return section;\n return (\n <ThemeOverrider activeTheme='dark' overrides={overrides}>\n {section}\n </ThemeOverrider>\n );\n }\n);\n\nSection.displayName = 'Section';\n\nexport default Section;\n"],"mappings":";;AAAA,OAAOA,KAAP,IAAgBC,UAAhB,QAAkC,OAAlC;AACA,SAASC,UAAT,QAAqC,mBAArC;AACA,SAASC,gBAAT,QAAiC,kBAAjC;AACA,OAAOC,MAAP,MAAmB,iBAAnB;AACA,SAASC,GAAT,EAAcC,cAAd,EAA8BC,QAA9B,QAA8C,oBAA9C;AACA,SAASC,KAAT,QAAkC,iBAAlC;AACA,SAASC,GAAT,QAAoB,gBAApB;AACA,SAASC,CAAT,QAAkB,kBAAlB;AA0BA,MAAMC,mBAAmB,GAAG,kBAA5B;;AAEA,MAAMC,WAAW,GAAIC,CAAD,IAClBA,CAAC,CAACC,KAAF,IACAL,GAAI;AACN,iBAAiBE,mBAAoB;AACrC;AACA;AACA,GANA;;AAWA,MAAMI,SAAS,GAAGX,MAAM,CACtB,SADsB,EAEtBD,gBAAgB,CAAC,OAAD,EAAU,MAAV,CAFM,CAGN;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,WAAb;IAA0B,GAAGC;EAA7B,IAA6CT,OAAnD;EACA,MAAM;IAAEU;EAAF,IAAgBjC,QAAQ,EAA9B;EAEA,MAAMkC,OAAO,gBACX,oBAAC,SAAD;IAAW,KAAK,EAAE,CAAC,CAACZ,KAApB;IAA2B,IAAI,EAAEI;EAAjC,GAA2CE,IAA3C;IAAiD,GAAG,EAAEC;EAAtD,IACGJ,YAAY,gBACX,oBAAC,YAAD;IAAc,QAAQ,EAAEP;EAAxB,GAAmCS,QAAnC,CADW,GAGXA,QAJJ,EAMGL,KAAK,iBACJ,oBAAC,eAAD;IACE,GAAG,EAAEA,KADP;IAEE,KAAK,MAFP;IAGE,SAAS,EAAE,CAACS,WAAD,EAAc3B,mBAAd,EACR+B,MADQ,CACAC,CAAD,IAAOA,CADN,EAERC,IAFQ,CAEH,GAFG;EAHb,GAMML,WANN,EAPJ,CADF;EAoBA,IAAI,CAACV,KAAL,EAAY,OAAOY,OAAP;EACZ,oBACE,oBAAC,cAAD;IAAgB,WAAW,EAAC,MAA5B;IAAmC,SAAS,EAAED;EAA9C,GACGC,OADH,CADF;AAKD,CA1CuB,CAA1B;AA6CAb,OAAO,CAACiB,WAAR,GAAsB,SAAtB;AAEA,eAAejB,OAAf"}
1
+ {"version":3,"file":"index.js","names":["React","forwardRef","sizeStyles","omitEmotionProps","styled","clr","ThemeOverrider","useTheme","Image","css","m","BG_IMAGE_CLASS_NAME","hasBgStyles","p","hasBg","Container","theme","sectionPaddingVertical","sectionPaddingHorizontal","min","sm","colorText","BackgroundImage","sectionBgImageBrightness","centeredStyles","centered","LimitedWidth","sectionMaxWidth","Section","bgUrl","bgProps","defaultSize","limitedWidth","size","children","rest","ref","className","bgClassName","restBgProps","overrides","section","filter","i","join","displayName"],"sources":["../../../src/Section/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport { sizeStyles, WithSize } from '@os-design/styles';\nimport { omitEmotionProps } from '@os-design/utils';\nimport styled from '@emotion/styled';\nimport { clr, ThemeOverrider, useTheme } from '@os-design/theming';\nimport { Image, ImageProps } from '@os-design/core';\nimport { css } from '@emotion/react';\nimport { m } from '@os-design/media';\n\ntype JsxSectionProps = Omit<JSX.IntrinsicElements['section'], 'ref'>;\nexport interface SectionProps extends JsxSectionProps, WithSize {\n /**\n * The URL of the background image.\n * @default undefined\n */\n bgUrl?: string;\n /**\n * Props of the background image.\n * @default undefined\n */\n bgProps?: Omit<ImageProps, 'url' | 'cover'>;\n /**\n * Whether the content has a limited width.\n * @default false\n */\n limitedWidth?: boolean;\n /**\n * Whether the content is centered.\n * @default false\n */\n centered?: boolean;\n}\n\nconst BG_IMAGE_CLASS_NAME = 'section-bg-image';\n\nconst hasBgStyles = (p) =>\n p.hasBg &&\n css`\n & > *:not(.${BG_IMAGE_CLASS_NAME}) {\n z-index: 1;\n }\n `;\n\ninterface ContainerProps extends WithSize {\n hasBg: boolean;\n}\nconst Container = styled(\n 'section',\n omitEmotionProps('hasBg', 'size')\n)<ContainerProps>`\n position: relative;\n\n display: flex;\n flex-direction: column;\n align-items: center;\n\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[0]}em;\n ${m.min.sm} {\n padding: ${(p) => p.theme.sectionPaddingVertical}em\n ${(p) => p.theme.sectionPaddingHorizontal[1]}em;\n }\n\n color: ${(p) => clr(p.theme.colorText)};\n\n ${hasBgStyles};\n ${sizeStyles};\n`;\n\nconst BackgroundImage = styled(Image)`\n // Reset image styles\n border-radius: 0;\n\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n filter: brightness(${(p) => p.theme.sectionBgImageBrightness}%);\n`;\n\nconst centeredStyles = (p) =>\n p.centered &&\n css`\n display: flex;\n flex-direction: column;\n align-items: center;\n text-align: center;\n `;\n\ninterface LimitedWidthProps {\n centered: boolean;\n}\nconst LimitedWidth = styled(\n 'div',\n omitEmotionProps('centered')\n)<LimitedWidthProps>`\n width: 100%;\n max-width: ${(p) => p.theme.sectionMaxWidth}em;\n ${centeredStyles};\n`;\n\n/**\n * The base section for the content.\n */\nconst Section = forwardRef<HTMLElement, SectionProps>(\n (\n {\n bgUrl,\n bgProps = { defaultSize: 1024 },\n limitedWidth = false,\n centered = false,\n size,\n children,\n ...rest\n },\n ref\n ) => {\n const { className: bgClassName, ...restBgProps } = bgProps;\n const { overrides } = useTheme();\n\n const section = (\n <Container hasBg={!!bgUrl} size={size} {...rest} ref={ref}>\n {limitedWidth ? (\n <LimitedWidth centered={centered}>{children}</LimitedWidth>\n ) : (\n children\n )}\n {bgUrl && (\n <BackgroundImage\n url={bgUrl}\n cover\n className={[bgClassName, BG_IMAGE_CLASS_NAME]\n .filter((i) => i)\n .join(' ')}\n {...restBgProps}\n />\n )}\n </Container>\n );\n\n if (!bgUrl) return section;\n return (\n <ThemeOverrider activeTheme='dark' overrides={overrides}>\n {section}\n </ThemeOverrider>\n );\n }\n);\n\nSection.displayName = 'Section';\n\nexport default Section;\n"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,UAAU,QAAQ,OAAO;AACzC,SAASC,UAAU,QAAkB,mBAAmB;AACxD,SAASC,gBAAgB,QAAQ,kBAAkB;AACnD,OAAOC,MAAM,MAAM,iBAAiB;AACpC,SAASC,GAAG,EAAEC,cAAc,EAAEC,QAAQ,QAAQ,oBAAoB;AAClE,SAASC,KAAK,QAAoB,iBAAiB;AACnD,SAASC,GAAG,QAAQ,gBAAgB;AACpC,SAASC,CAAC,QAAQ,kBAAkB;AA0BpC,MAAMC,mBAAmB,GAAG,kBAAkB;AAE9C,MAAMC,WAAW,GAAIC,CAAC,IACpBA,CAAC,CAACC,KAAK,IACPL,GAAI;AACN,iBAAiBE,mBAAoB;AACrC;AACA;AACA,GAAG;AAKH,MAAMI,SAAS,GAAGX,MAAM,CACtB,SAAS,EACTD,gBAAgB,CAAC,OAAO,EAAE,MAAM,CAAC,CACjB;AAClB;AACA;AACA;AACA;AACA;AACA;AACA,aAAcU,CAAC,IAAKA,CAAC,CAAC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,EAAE;EAEhC,MAAMkC,OAAO,gBACX,oBAAC,SAAS;IAAC,KAAK,EAAE,CAAC,CAACZ,KAAM;IAAC,IAAI,EAAEI;EAAK,GAAKE,IAAI;IAAE,GAAG,EAAEC;EAAI,IACvDJ,YAAY,gBACX,oBAAC,YAAY;IAAC,QAAQ,EAAEP;EAAS,GAAES,QAAQ,CAAgB,GAE3DA,QACD,EACAL,KAAK,iBACJ,oBAAC,eAAe;IACd,GAAG,EAAEA,KAAM;IACX,KAAK;IACL,SAAS,EAAE,CAACS,WAAW,EAAE3B,mBAAmB,CAAC,CAC1C+B,MAAM,CAAEC,CAAC,IAAKA,CAAC,CAAC,CAChBC,IAAI,CAAC,GAAG;EAAE,GACTL,WAAW,EAElB,CAEJ;EAED,IAAI,CAACV,KAAK,EAAE,OAAOY,OAAO;EAC1B,oBACE,oBAAC,cAAc;IAAC,WAAW,EAAC,MAAM;IAAC,SAAS,EAAED;EAAU,GACrDC,OAAO,CACO;AAErB,CAAC,CACF;AAEDb,OAAO,CAACiB,WAAW,GAAG,SAAS;AAE/B,eAAejB,OAAO"}
@@ -1,5 +1,4 @@
1
1
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
-
3
2
  import React, { forwardRef } from 'react';
4
3
  import styled from '@emotion/styled';
5
4
  import { css } from '@emotion/react';
@@ -7,7 +6,6 @@ import { omitEmotionProps } from '@os-design/utils';
7
6
  import { m } from '@os-design/media';
8
7
  import { clr } from '@os-design/theming';
9
8
  import Section from '../Section';
10
-
11
9
  const containerHasMediaStyles = p => p.hasMedia && css`
12
10
  display: grid;
13
11
 
@@ -29,11 +27,9 @@ const containerHasMediaStyles = p => p.hasMedia && css`
29
27
  padding-right: ${p.theme.sectionFeatureColumnGapPercent * 2}%;
30
28
  }
31
29
  `;
32
-
33
30
  const containerNotHasMediaStyles = p => !p.hasMedia && css`
34
31
  max-width: ${p.theme.sectionFeatureContentMaxWidth}em;
35
32
  `;
36
-
37
33
  const Container = styled('div', omitEmotionProps('hasMedia'))`
38
34
  color: ${p => clr(p.theme.colorText)};
39
35
  ${containerHasMediaStyles};
@@ -47,7 +43,6 @@ const Media = styled.div`
47
43
  grid-area: media;
48
44
  align-self: center;
49
45
  `;
50
-
51
46
  const sectionHasMediaStyles = p => p.hasMedia && css`
52
47
  ${m.min.md} {
53
48
  &:nth-of-type(even) {
@@ -61,14 +56,13 @@ const sectionHasMediaStyles = p => p.hasMedia && css`
61
56
  }
62
57
  }
63
58
  `;
64
-
65
59
  const StyledSection = styled(Section, omitEmotionProps('hasMedia'))`
66
60
  ${sectionHasMediaStyles};
67
61
  `;
62
+
68
63
  /**
69
64
  * The section for describing an app feature.
70
65
  */
71
-
72
66
  const SectionFeature = /*#__PURE__*/forwardRef(({
73
67
  media,
74
68
  children,
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["React","forwardRef","styled","css","omitEmotionProps","m","clr","Section","containerHasMediaStyles","p","hasMedia","theme","sectionFeatureRowGap","min","md","sectionFeatureMediaWidthPercent","sectionFeatureContentMaxWidth","sectionFeatureColumnGapPercent","containerNotHasMediaStyles","Container","colorText","Content","div","Media","sectionHasMediaStyles","StyledSection","SectionFeature","media","children","rest","ref","displayName"],"sources":["../../../src/SectionFeature/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport styled from '@emotion/styled';\nimport { css } from '@emotion/react';\nimport { omitEmotionProps } from '@os-design/utils';\nimport { m } from '@os-design/media';\nimport { clr } from '@os-design/theming';\nimport Section, { SectionProps } from '../Section';\n\nexport interface SectionFeatureProps extends SectionProps {\n /**\n * The media component. For example, an image.\n * @default undefined\n */\n media?: React.ReactElement;\n}\n\nconst containerHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n display: grid;\n\n grid-template-columns: 1fr;\n grid-template-rows: auto auto;\n grid-template-areas: 'content' 'media';\n grid-row-gap: ${p.theme.sectionFeatureRowGap}em;\n\n ${m.min.md} {\n grid-template-columns:\n minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n )\n ${p.theme.sectionFeatureMediaWidthPercent}%;\n grid-template-rows: 1fr;\n grid-template-areas: 'content media';\n grid-column-gap: ${p.theme.sectionFeatureColumnGapPercent}%;\n padding-right: ${p.theme.sectionFeatureColumnGapPercent * 2}%;\n }\n `;\n\nconst containerNotHasMediaStyles = (p) =>\n !p.hasMedia &&\n css`\n max-width: ${p.theme.sectionFeatureContentMaxWidth}em;\n `;\n\ninterface ContainerProps {\n hasMedia: boolean;\n}\nconst Container = styled('div', omitEmotionProps('hasMedia'))<ContainerProps>`\n color: ${(p) => clr(p.theme.colorText)};\n ${containerHasMediaStyles};\n ${containerNotHasMediaStyles};\n`;\n\nconst Content = styled.div`\n grid-area: content;\n align-self: center;\n`;\n\nconst Media = styled.div`\n grid-area: media;\n align-self: center;\n`;\n\nconst sectionHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n ${m.min.md} {\n &:nth-of-type(even) {\n & > div {\n grid-template-areas: 'media content';\n grid-template-columns: ${p.theme.sectionFeatureMediaWidthPercent}% minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n );\n }\n }\n }\n `;\n\ninterface StyledSectionProps {\n hasMedia: boolean;\n}\nconst StyledSection = styled(\n Section,\n omitEmotionProps('hasMedia')\n)<StyledSectionProps>`\n ${sectionHasMediaStyles};\n`;\n\n/**\n * The section for describing an app feature.\n */\nconst SectionFeature = forwardRef<HTMLElement, SectionFeatureProps>(\n ({ media, children, ...rest }, ref) => (\n <StyledSection hasMedia={!!media} {...rest} ref={ref}>\n <Container hasMedia={!!media}>\n <Content>{children}</Content>\n {media && <Media>{media}</Media>}\n </Container>\n </StyledSection>\n )\n);\n\nSectionFeature.displayName =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K,GAAGrB,MAAM,CAACoB,GAAI;AACzB;AACA;AACA,CAHA;;AAKA,MAAME,qBAAqB,GAAIf,CAAD,IAC5BA,CAAC,CAACC,QAAF,IACAP,GAAI;AACN,MAAME,CAAC,CAACQ,GAAF,CAAMC,EAAG;AACf;AACA;AACA;AACA,mCAAmCL,CAAC,CAACE,KAAF,CAAQI,+BAAgC;AAC3E,gBAAgB,MAAMN,CAAC,CAACE,KAAF,CAAQI,+BAAgC;AAC9D,gBAAgBN,CAAC,CAACE,KAAF,CAAQK,6BAA8B;AACtD;AACA;AACA;AACA;AACA,GAdA;;AAmBA,MAAMS,aAAa,GAAGvB,MAAM,CAC1BK,OAD0B,EAE1BH,gBAAgB,CAAC,UAAD,CAFU,CAGN;AACtB,IAAIoB,qBAAsB;AAC1B,CALA;AAOA;AACA;AACA;;AACA,MAAME,cAAc,gBAAGzB,UAAU,CAC/B,CAAC;EAAE0B,KAAF;EAASC,QAAT;EAAmB,GAAGC;AAAtB,CAAD,EAA+BC,GAA/B,kBACE,oBAAC,aAAD;EAAe,QAAQ,EAAE,CAAC,CAACH;AAA3B,GAAsCE,IAAtC;EAA4C,GAAG,EAAEC;AAAjD,iBACE,oBAAC,SAAD;EAAW,QAAQ,EAAE,CAAC,CAACH;AAAvB,gBACE,oBAAC,OAAD,QAAUC,QAAV,CADF,EAEGD,KAAK,iBAAI,oBAAC,KAAD,QAAQA,KAAR,CAFZ,CADF,CAF6B,CAAjC;AAWAD,cAAc,CAACK,WAAf,GAA6B,gBAA7B;AAEA,eAAeL,cAAf"}
1
+ {"version":3,"file":"index.js","names":["React","forwardRef","styled","css","omitEmotionProps","m","clr","Section","containerHasMediaStyles","p","hasMedia","theme","sectionFeatureRowGap","min","md","sectionFeatureMediaWidthPercent","sectionFeatureContentMaxWidth","sectionFeatureColumnGapPercent","containerNotHasMediaStyles","Container","colorText","Content","div","Media","sectionHasMediaStyles","StyledSection","SectionFeature","media","children","rest","ref","displayName"],"sources":["../../../src/SectionFeature/index.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\nimport styled from '@emotion/styled';\nimport { css } from '@emotion/react';\nimport { omitEmotionProps } from '@os-design/utils';\nimport { m } from '@os-design/media';\nimport { clr } from '@os-design/theming';\nimport Section, { SectionProps } from '../Section';\n\nexport interface SectionFeatureProps extends SectionProps {\n /**\n * The media component. For example, an image.\n * @default undefined\n */\n media?: React.ReactElement;\n}\n\nconst containerHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n display: grid;\n\n grid-template-columns: 1fr;\n grid-template-rows: auto auto;\n grid-template-areas: 'content' 'media';\n grid-row-gap: ${p.theme.sectionFeatureRowGap}em;\n\n ${m.min.md} {\n grid-template-columns:\n minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n )\n ${p.theme.sectionFeatureMediaWidthPercent}%;\n grid-template-rows: 1fr;\n grid-template-areas: 'content media';\n grid-column-gap: ${p.theme.sectionFeatureColumnGapPercent}%;\n padding-right: ${p.theme.sectionFeatureColumnGapPercent * 2}%;\n }\n `;\n\nconst containerNotHasMediaStyles = (p) =>\n !p.hasMedia &&\n css`\n max-width: ${p.theme.sectionFeatureContentMaxWidth}em;\n `;\n\ninterface ContainerProps {\n hasMedia: boolean;\n}\nconst Container = styled('div', omitEmotionProps('hasMedia'))<ContainerProps>`\n color: ${(p) => clr(p.theme.colorText)};\n ${containerHasMediaStyles};\n ${containerNotHasMediaStyles};\n`;\n\nconst Content = styled.div`\n grid-area: content;\n align-self: center;\n`;\n\nconst Media = styled.div`\n grid-area: media;\n align-self: center;\n`;\n\nconst sectionHasMediaStyles = (p) =>\n p.hasMedia &&\n css`\n ${m.min.md} {\n &:nth-of-type(even) {\n & > div {\n grid-template-areas: 'media content';\n grid-template-columns: ${p.theme.sectionFeatureMediaWidthPercent}% minmax(\n ${100 - p.theme.sectionFeatureMediaWidthPercent}%,\n ${p.theme.sectionFeatureContentMaxWidth}em\n );\n }\n }\n }\n `;\n\ninterface StyledSectionProps {\n hasMedia: boolean;\n}\nconst StyledSection = styled(\n Section,\n omitEmotionProps('hasMedia')\n)<StyledSectionProps>`\n ${sectionHasMediaStyles};\n`;\n\n/**\n * The section for describing an app feature.\n */\nconst SectionFeature = forwardRef<HTMLElement, SectionFeatureProps>(\n ({ media, children, ...rest }, ref) => (\n <StyledSection hasMedia={!!media} {...rest} ref={ref}>\n <Container hasMedia={!!media}>\n <Content>{children}</Content>\n {media && <Media>{media}</Media>}\n </Container>\n </StyledSection>\n )\n);\n\nSectionFeature.displayName = 'SectionFeature';\n\nexport default SectionFeature;\n"],"mappings":";AAAA,OAAOA,KAAK,IAAIC,UAAU,QAAQ,OAAO;AACzC,OAAOC,MAAM,MAAM,iBAAiB;AACpC,SAASC,GAAG,QAAQ,gBAAgB;AACpC,SAASC,gBAAgB,QAAQ,kBAAkB;AACnD,SAASC,CAAC,QAAQ,kBAAkB;AACpC,SAASC,GAAG,QAAQ,oBAAoB;AACxC,OAAOC,OAAO,MAAwB,YAAY;AAUlD,MAAMC,uBAAuB,GAAIC,CAAC,IAChCA,CAAC,CAACC,QAAQ,IACVP,GAAI;AACN;AACA;AACA;AACA;AACA;AACA,oBAAoBM,CAAC,CAACE,KAAK,CAACC,oBAAqB;AACjD;AACA,MAAMP,CAAC,CAACQ,GAAG,CAACC,EAAG;AACf;AACA;AACA,YAAY,GAAG,GAAGL,CAAC,CAACE,KAAK,CAACI,+BAAgC;AAC1D,YAAYN,CAAC,CAACE,KAAK,CAACK,6BAA8B;AAClD;AACA,UAAUP,CAAC,CAACE,KAAK,CAACI,+BAAgC;AAClD;AACA;AACA,yBAAyBN,CAAC,CAACE,KAAK,CAACM,8BAA+B;AAChE,uBAAuBR,CAAC,CAACE,KAAK,CAACM,8BAA8B,GAAG,CAAE;AAClE;AACA,GAAG;AAEH,MAAMC,0BAA0B,GAAIT,CAAC,IACnC,CAACA,CAAC,CAACC,QAAQ,IACXP,GAAI;AACN,iBAAiBM,CAAC,CAACE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,cAAc,CAACK,WAAW,GAAG,gBAAgB;AAE7C,eAAeL,cAAc"}
@@ -1 +1 @@
1
- {"version":3,"file":"emotion.d.js","names":[],"sources":["../../src/emotion.d.ts"],"sourcesContent":["import '@emotion/react';\nimport { Theme as BaseTheme } from '@os-design/theming';\n\ndeclare module '@emotion/react' {\n // eslint-disable-next-line @typescript-eslint/no-empty-interface\n export interface Theme extends BaseTheme {}\n}\n"],"mappings":"AAAA,OAAO,gBAAP"}
1
+ {"version":3,"file":"emotion.d.js","names":[],"sources":["../../src/emotion.d.ts"],"sourcesContent":["import '@emotion/react';\nimport { Theme as BaseTheme } from '@os-design/theming';\n\ndeclare module '@emotion/react' {\n // eslint-disable-next-line @typescript-eslint/no-empty-interface\n export interface Theme extends BaseTheme {}\n}\n"],"mappings":"AAAA,OAAO,gBAAgB"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","names":["default","PageContent","Section","SectionFeature"],"sources":["../../src/index.ts"],"sourcesContent":["export { default as PageContent } from './PageContent';\nexport { default as Section } from './Section';\nexport { default as SectionFeature } from './SectionFeature';\n\nexport * from './PageContent';\nexport * from './Section';\nexport * from './SectionFeature';\n"],"mappings":"AAAA,SAASA,OAAO,IAAIC,WAApB,QAAuC,eAAvC;AACA,SAASD,OAAO,IAAIE,OAApB,QAAmC,WAAnC;AACA,SAASF,OAAO,IAAIG,cAApB,QAA0C,kBAA1C;AAEA,cAAc,eAAd;AACA,cAAc,WAAd;AACA,cAAc,kBAAd"}
1
+ {"version":3,"file":"index.js","names":["default","PageContent","Section","SectionFeature"],"sources":["../../src/index.ts"],"sourcesContent":["export { default as PageContent } from './PageContent';\nexport { default as Section } from './Section';\nexport { default as SectionFeature } from './SectionFeature';\n\nexport * from './PageContent';\nexport * from './Section';\nexport * from './SectionFeature';\n"],"mappings":"AAAA,SAASA,OAAO,IAAIC,WAAW,QAAQ,eAAe;AACtD,SAASD,OAAO,IAAIE,OAAO,QAAQ,WAAW;AAC9C,SAASF,OAAO,IAAIG,cAAc,QAAQ,kBAAkB;AAE5D,cAAc,eAAe;AAC7B,cAAc,WAAW;AACzB,cAAc,kBAAkB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@os-design/website",
3
- "version": "1.0.158",
3
+ "version": "1.0.160",
4
4
  "license": "UNLICENSED",
5
5
  "repository": "git@gitlab.com:os-team/libs/os-design.git",
6
6
  "main": "dist/cjs/index.js",
@@ -29,7 +29,7 @@
29
29
  "access": "public"
30
30
  },
31
31
  "dependencies": {
32
- "@os-design/core": "^1.0.156",
32
+ "@os-design/core": "^1.0.158",
33
33
  "@os-design/media": "^1.0.15",
34
34
  "@os-design/styles": "^1.0.39",
35
35
  "@os-design/theming": "^1.0.37",
@@ -46,5 +46,5 @@
46
46
  "react": ">=18",
47
47
  "react-dom": ">=18"
48
48
  },
49
- "gitHead": "5a2a0d8ca15882259f4f84a52faca3e43f79841b"
49
+ "gitHead": "1f7502d2714949d3dabaa8e103a4e315fda8e2f8"
50
50
  }