@os-design/website 1.0.198 → 1.0.200
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/dist/cjs/@types/emotion.d.js.map +1 -1
- package/dist/cjs/PageContent/index.js.map +1 -1
- package/dist/cjs/Section/index.js +13 -13
- package/dist/cjs/Section/index.js.map +1 -1
- package/dist/cjs/SectionFeature/index.js +11 -11
- package/dist/cjs/SectionFeature/index.js.map +1 -1
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/Section/index.js +5 -5
- package/dist/esm/Section/index.js.map +1 -1
- package/dist/esm/SectionFeature/index.js +3 -3
- package/dist/esm/SectionFeature/index.js.map +1 -1
- package/dist/types/Section/index.d.ts +2 -2
- package/dist/types/Section/index.d.ts.map +1 -1
- package/dist/types/SectionFeature/index.d.ts.map +1 -1
- package/package.json +7 -7
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"emotion.d.js","names":[],"sources":["../../../src/@types/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":";;
|
|
1
|
+
{"version":3,"file":"emotion.d.js","names":["require"],"sources":["../../../src/@types/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":";;AAAAA,OAAA"}
|
|
@@ -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;AAGyB;AAAA;AAAA;AAIzB;AACA;AACA;AACA,
|
|
1
|
+
{"version":3,"file":"index.js","names":["_styled","_interopRequireDefault","require","_core","_templateObject","obj","__esModule","_taggedTemplateLiteral","strings","raw","slice","Object","freeze","defineProperties","value","PageContent","styled","BasePageContent","_default","exports"],"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,IAAAA,OAAA,GAAAC,sBAAA,CAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AAGyB,IAAAE,eAAA;AAAA,SAAAH,uBAAAI,GAAA,WAAAA,GAAA,IAAAA,GAAA,CAAAC,UAAA,GAAAD,GAAA,gBAAAA,GAAA;AAAA,SAAAE,uBAAAC,OAAA,EAAAC,GAAA,SAAAA,GAAA,IAAAA,GAAA,GAAAD,OAAA,CAAAE,KAAA,cAAAC,MAAA,CAAAC,MAAA,CAAAD,MAAA,CAAAE,gBAAA,CAAAL,OAAA,IAAAC,GAAA,IAAAK,KAAA,EAAAH,MAAA,CAAAC,MAAA,CAAAH,GAAA;AAIzB;AACA;AACA;AACA,IAAMM,WAAW,GAAG,IAAAC,kBAAM,EAACC,iBAAe,CAAC,CAAAb,eAAA,KAAAA,eAAA,GAAAG,sBAAA,oCAE1C;AAAC,IAAAW,QAAA,GAEaH,WAAW;AAAAI,OAAA,cAAAD,QAAA"}
|
|
@@ -5,27 +5,27 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports["default"] = void 0;
|
|
8
|
-
var _react =
|
|
9
|
-
var _styles = require("@os-design/styles");
|
|
10
|
-
var _utils = require("@os-design/utils");
|
|
8
|
+
var _react = require("@emotion/react");
|
|
11
9
|
var _styled = _interopRequireDefault(require("@emotion/styled"));
|
|
12
|
-
var _theming = require("@os-design/theming");
|
|
13
10
|
var _core = require("@os-design/core");
|
|
14
|
-
var _react2 = require("@emotion/react");
|
|
15
11
|
var _media = require("@os-design/media");
|
|
12
|
+
var _styles = require("@os-design/styles");
|
|
13
|
+
var _theming = require("@os-design/theming");
|
|
14
|
+
var _utils = require("@os-design/utils");
|
|
15
|
+
var _react2 = _interopRequireWildcard(require("react"));
|
|
16
16
|
var _excluded = ["bgUrl", "bgProps", "limitedWidth", "centered", "size", "children"],
|
|
17
17
|
_excluded2 = ["className"];
|
|
18
18
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5;
|
|
19
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
20
19
|
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); }
|
|
21
20
|
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; }
|
|
21
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
22
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); }
|
|
23
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; }
|
|
24
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; }
|
|
25
25
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
26
26
|
var BG_IMAGE_CLASS_NAME = 'section-bg-image';
|
|
27
27
|
var hasBgStyles = function hasBgStyles(p) {
|
|
28
|
-
return p.hasBg && (0,
|
|
28
|
+
return p.hasBg && (0, _react.css)(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n & > *:not(.", ") {\n z-index: 1;\n }\n "])), BG_IMAGE_CLASS_NAME);
|
|
29
29
|
};
|
|
30
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) {
|
|
31
31
|
return p.theme.sectionPaddingVertical;
|
|
@@ -42,7 +42,7 @@ var BackgroundImage = (0, _styled["default"])(_core.Image)(_templateObject3 || (
|
|
|
42
42
|
return p.theme.sectionBgImageBrightness;
|
|
43
43
|
});
|
|
44
44
|
var centeredStyles = function centeredStyles(p) {
|
|
45
|
-
return p.centered && (0,
|
|
45
|
+
return p.centered && (0, _react.css)(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n align-items: center;\n text-align: center;\n "])));
|
|
46
46
|
};
|
|
47
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) {
|
|
48
48
|
return p.theme.sectionMaxWidth;
|
|
@@ -51,7 +51,7 @@ var LimitedWidth = (0, _styled["default"])('div', (0, _utils.omitEmotionProps)('
|
|
|
51
51
|
/**
|
|
52
52
|
* The base section for the content.
|
|
53
53
|
*/
|
|
54
|
-
var Section = /*#__PURE__*/(0,
|
|
54
|
+
var Section = /*#__PURE__*/(0, _react2.forwardRef)(function (_ref, ref) {
|
|
55
55
|
var bgUrl = _ref.bgUrl,
|
|
56
56
|
_ref$bgProps = _ref.bgProps,
|
|
57
57
|
bgProps = _ref$bgProps === void 0 ? {
|
|
@@ -68,14 +68,14 @@ var Section = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
68
68
|
restBgProps = _objectWithoutProperties(bgProps, _excluded2);
|
|
69
69
|
var _useTheme = (0, _theming.useTheme)(),
|
|
70
70
|
overrides = _useTheme.overrides;
|
|
71
|
-
var section = /*#__PURE__*/
|
|
71
|
+
var section = /*#__PURE__*/_react2["default"].createElement(Container, _extends({
|
|
72
72
|
hasBg: !!bgUrl,
|
|
73
73
|
size: size
|
|
74
74
|
}, rest, {
|
|
75
75
|
ref: ref
|
|
76
|
-
}), limitedWidth ? /*#__PURE__*/
|
|
76
|
+
}), limitedWidth ? /*#__PURE__*/_react2["default"].createElement(LimitedWidth, {
|
|
77
77
|
centered: centered
|
|
78
|
-
}, children) : children, bgUrl && /*#__PURE__*/
|
|
78
|
+
}, children) : children, bgUrl && /*#__PURE__*/_react2["default"].createElement(BackgroundImage, _extends({
|
|
79
79
|
url: bgUrl,
|
|
80
80
|
cover: true,
|
|
81
81
|
className: [bgClassName, BG_IMAGE_CLASS_NAME].filter(function (i) {
|
|
@@ -83,7 +83,7 @@ var Section = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
|
83
83
|
}).join(' ')
|
|
84
84
|
}, restBgProps)));
|
|
85
85
|
if (!bgUrl) return section;
|
|
86
|
-
return /*#__PURE__*/
|
|
86
|
+
return /*#__PURE__*/_react2["default"].createElement(_theming.ThemeOverrider, {
|
|
87
87
|
activeTheme: "dark",
|
|
88
88
|
overrides: overrides
|
|
89
89
|
}, section);
|
|
@@ -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;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;AAAA,GAC5C,UAACP,CAAC;EAAA,OAAKA,CAAC,CAACM,KAAK,CAACE,wBAAwB,CAAC,CA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AY;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
|
+
{"version":3,"file":"index.js","names":["_react","require","_styled","_interopRequireDefault","_core","_media","_styles","_theming","_utils","_react2","_interopRequireWildcard","_excluded","_excluded2","_templateObject","_templateObject2","_templateObject3","_templateObject4","_templateObject5","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_extends","assign","bind","target","i","arguments","length","source","apply","_objectWithoutProperties","excluded","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","indexOf","propertyIsEnumerable","sourceKeys","keys","_taggedTemplateLiteral","strings","raw","slice","freeze","defineProperties","value","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","ref","bgUrl","_ref$bgProps","bgProps","defaultSize","_ref$limitedWidth","limitedWidth","_ref$centered","size","children","rest","bgClassName","className","restBgProps","_useTheme","useTheme","overrides","section","createElement","url","cover","filter","join","ThemeOverrider","activeTheme","displayName","_default","exports"],"sources":["../../../src/Section/index.tsx"],"sourcesContent":["import { css } from '@emotion/react';\n\nimport styled from '@emotion/styled';\n\nimport { Image, ImageProps } from '@os-design/core';\n\nimport { m } from '@os-design/media';\nimport { sizeStyles, WithSize } from '@os-design/styles';\nimport { clr, ThemeOverrider, useTheme } from '@os-design/theming';\nimport { omitEmotionProps } from '@os-design/utils';\nimport React, { forwardRef } from 'react';\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,IAAAA,MAAA,GAAAC,OAAA;AAEA,IAAAC,OAAA,GAAAC,sBAAA,CAAAF,OAAA;AAEA,IAAAG,KAAA,GAAAH,OAAA;AAEA,IAAAI,MAAA,GAAAJ,OAAA;AACA,IAAAK,OAAA,GAAAL,OAAA;AACA,IAAAM,QAAA,GAAAN,OAAA;AACA,IAAAO,MAAA,GAAAP,OAAA;AACA,IAAAQ,OAAA,GAAAC,uBAAA,CAAAT,OAAA;AAA0C,IAAAU,SAAA;EAAAC,UAAA;AAAA,IAAAC,eAAA,EAAAC,gBA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Q,EAAC,CAAC;IAAxBC,SAAS,GAAAF,SAAA,CAATE,SAAS;EAEjB,IAAMC,OAAO,gBACXpG,OAAA,YAAAqG,aAAA,CAACxC,SAAS,EAAA9B,QAAA;IAAC4B,KAAK,EAAE,CAAC,CAACyB,KAAM;IAACO,IAAI,EAAEA;EAAK,GAAKE,IAAI;IAAEV,GAAG,EAAEA;EAAI,IACvDM,YAAY,gBACXzF,OAAA,YAAAqG,aAAA,CAACvB,YAAY;IAACD,QAAQ,EAAEA;EAAS,GAAEe,QAAuB,CAAC,GAE3DA,QACD,EACAR,KAAK,iBACJpF,OAAA,YAAAqG,aAAA,CAAC5B,eAAe,EAAA1C,QAAA;IACduE,GAAG,EAAElB,KAAM;IACXmB,KAAK;IACLR,SAAS,EAAE,CAACD,WAAW,EAAEtC,mBAAmB,CAAC,CAC1CgD,MAAM,CAAC,UAACrE,CAAC;MAAA,OAAKA,CAAC;IAAA,EAAC,CAChBsE,IAAI,CAAC,GAAG;EAAE,GACTT,WAAW,CAChB,CAEM,CACZ;EAED,IAAI,CAACZ,KAAK,EAAE,OAAOgB,OAAO;EAC1B,oBACEpG,OAAA,YAAAqG,aAAA,CAACvG,QAAA,CAAA4G,cAAc;IAACC,WAAW,EAAC,MAAM;IAACR,SAAS,EAAEA;EAAU,GACrDC,OACa,CAAC;AAErB,CACF,CAAC;AAEDpB,OAAO,CAAC4B,WAAW,GAAG,SAAS;AAAC,IAAAC,QAAA,GAEjB7B,OAAO;AAAA8B,OAAA,cAAAD,QAAA"}
|
|
@@ -5,27 +5,27 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
7
|
exports["default"] = void 0;
|
|
8
|
-
var _react =
|
|
8
|
+
var _react = require("@emotion/react");
|
|
9
9
|
var _styled = _interopRequireDefault(require("@emotion/styled"));
|
|
10
|
-
var _react2 = require("@emotion/react");
|
|
11
|
-
var _utils = require("@os-design/utils");
|
|
12
10
|
var _media = require("@os-design/media");
|
|
13
11
|
var _theming = require("@os-design/theming");
|
|
12
|
+
var _utils = require("@os-design/utils");
|
|
13
|
+
var _react2 = _interopRequireWildcard(require("react"));
|
|
14
14
|
var _Section = _interopRequireDefault(require("../Section"));
|
|
15
15
|
var _excluded = ["media", "children"];
|
|
16
16
|
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7;
|
|
17
|
-
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
18
17
|
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); }
|
|
19
18
|
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; }
|
|
19
|
+
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { "default": obj }; }
|
|
20
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); }
|
|
21
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; }
|
|
22
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; }
|
|
23
23
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
24
24
|
var containerHasMediaStyles = function containerHasMediaStyles(p) {
|
|
25
|
-
return p.hasMedia && (0,
|
|
25
|
+
return p.hasMedia && (0, _react.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);
|
|
26
26
|
};
|
|
27
27
|
var containerNotHasMediaStyles = function containerNotHasMediaStyles(p) {
|
|
28
|
-
return !p.hasMedia && (0,
|
|
28
|
+
return !p.hasMedia && (0, _react.css)(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n max-width: ", "em;\n "])), p.theme.sectionFeatureContentMaxWidth);
|
|
29
29
|
};
|
|
30
30
|
var Container = (0, _styled["default"])('div', (0, _utils.omitEmotionProps)('hasMedia'))(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n color: ", ";\n ", ";\n ", ";\n"])), function (p) {
|
|
31
31
|
return (0, _theming.clr)(p.theme.colorText);
|
|
@@ -33,24 +33,24 @@ var Container = (0, _styled["default"])('div', (0, _utils.omitEmotionProps)('has
|
|
|
33
33
|
var Content = _styled["default"].div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n grid-area: content;\n align-self: center;\n"])));
|
|
34
34
|
var Media = _styled["default"].div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n grid-area: media;\n align-self: center;\n"])));
|
|
35
35
|
var sectionHasMediaStyles = function sectionHasMediaStyles(p) {
|
|
36
|
-
return p.hasMedia && (0,
|
|
36
|
+
return p.hasMedia && (0, _react.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);
|
|
37
37
|
};
|
|
38
38
|
var StyledSection = (0, _styled["default"])(_Section["default"], (0, _utils.omitEmotionProps)('hasMedia'))(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n ", ";\n"])), sectionHasMediaStyles);
|
|
39
39
|
|
|
40
40
|
/**
|
|
41
41
|
* The section for describing an app feature.
|
|
42
42
|
*/
|
|
43
|
-
var SectionFeature = /*#__PURE__*/(0,
|
|
43
|
+
var SectionFeature = /*#__PURE__*/(0, _react2.forwardRef)(function (_ref, ref) {
|
|
44
44
|
var media = _ref.media,
|
|
45
45
|
children = _ref.children,
|
|
46
46
|
rest = _objectWithoutProperties(_ref, _excluded);
|
|
47
|
-
return /*#__PURE__*/
|
|
47
|
+
return /*#__PURE__*/_react2["default"].createElement(StyledSection, _extends({
|
|
48
48
|
hasMedia: !!media
|
|
49
49
|
}, rest, {
|
|
50
50
|
ref: ref
|
|
51
|
-
}), /*#__PURE__*/
|
|
51
|
+
}), /*#__PURE__*/_react2["default"].createElement(Container, {
|
|
52
52
|
hasMedia: !!media
|
|
53
|
-
}, /*#__PURE__*/
|
|
53
|
+
}, /*#__PURE__*/_react2["default"].createElement(Content, null, children), media && /*#__PURE__*/_react2["default"].createElement(Media, null, media)));
|
|
54
54
|
});
|
|
55
55
|
SectionFeature.displayName = 'SectionFeature';
|
|
56
56
|
var _default = SectionFeature;
|
|
@@ -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
|
|
1
|
+
{"version":3,"file":"index.js","names":["_react","require","_styled","_interopRequireDefault","_media","_theming","_utils","_react2","_interopRequireWildcard","_Section","_excluded","_templateObject","_templateObject2","_templateObject3","_templateObject4","_templateObject5","_templateObject6","_templateObject7","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","get","newObj","hasPropertyDescriptor","Object","defineProperty","getOwnPropertyDescriptor","key","prototype","hasOwnProperty","call","desc","set","_extends","assign","bind","target","i","arguments","length","source","apply","_objectWithoutProperties","excluded","_objectWithoutPropertiesLoose","getOwnPropertySymbols","sourceSymbolKeys","indexOf","propertyIsEnumerable","sourceKeys","keys","_taggedTemplateLiteral","strings","raw","slice","freeze","defineProperties","value","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","ref","media","children","rest","createElement","displayName","_default","exports"],"sources":["../../../src/SectionFeature/index.tsx"],"sourcesContent":["import { css } from '@emotion/react';\n\nimport styled from '@emotion/styled';\n\nimport { m } from '@os-design/media';\nimport { clr } from '@os-design/theming';\nimport { omitEmotionProps } from '@os-design/utils';\nimport React, { forwardRef } from 'react';\n\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,IAAAA,MAAA,GAAAC,OAAA;AAEA,IAAAC,OAAA,GAAAC,sBAAA,CAAAF,OAAA;AAEA,IAAAG,MAAA,GAAAH,OAAA;AACA,IAAAI,QAAA,GAAAJ,OAAA;AACA,IAAAK,MAAA,GAAAL,OAAA;AACA,IAAAM,OAAA,GAAAC,uBAAA,CAAAP,OAAA;AAEA,IAAAQ,QAAA,GAAAN,sBAAA,CAAAF,OAAA;AAAmD,IAAAS,SAAA;AAAA,IAAAC,eAAA,EAAAC,gBAAA,EAAAC,gBAAA,EAAAC,gBAAA,EAAAC,gBAAA,EAAAC,gBAAA,EAAAC,gBAAA;AAAA,SAAAC,yBAAAC,WAAA,eAAAC,OAAA,kCAAAC,iBAAA,OAAAD,OAAA,QAAAE,gBAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,yBAAAC,WAAA,WAAAA,WAAA,GAAAG,gBAAA,GAAAD,iBAAA,KAAAF,WAAA;AAAA,SA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AA"}
|
package/dist/cjs/index.js.map
CHANGED
|
@@ -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;
|
|
1
|
+
{"version":3,"file":"index.js","names":["_PageContent","_interopRequireWildcard","require","Object","keys","forEach","key","prototype","hasOwnProperty","call","_exportNames","exports","defineProperty","enumerable","get","_Section","_SectionFeature","_getRequireWildcardCache","nodeInterop","WeakMap","cacheBabelInterop","cacheNodeInterop","obj","__esModule","_typeof","cache","has","newObj","hasPropertyDescriptor","getOwnPropertyDescriptor","desc","set"],"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,IAAAA,YAAA,GAAAC,uBAAA,CAAAC,OAAA;AAIAC,MAAA,CAAAC,IAAA,CAAAJ,YAAA,EAAAK,OAAA,WAAAC,GAAA;EAAA,IAAAA,GAAA,kBAAAA,GAAA;EAAA,IAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAC,YAAA,EAAAJ,GAAA;EAAA,IAAAA,GAAA,IAAAK,OAAA,IAAAA,OAAA,CAAAL,GAAA,MAAAN,YAAA,CAAAM,GAAA;EAAAH,MAAA,CAAAS,cAAA,CAAAD,OAAA,EAAAL,GAAA;IAAAO,UAAA;IAAAC,GAAA,WAAAA,IAAA;MAAA,OAAAd,YAAA,CAAAM,GAAA;IAAA;EAAA;AAAA;AAHA,IAAAS,QAAA,GAAAd,uBAAA,CAAAC,OAAA;AAIAC,MA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AAA,UAAAG,KAAA,GAAAR,wBAAA,CAAAC,WAAA,OAAAO,KAAA,IAAAA,KAAA,CAAAC,GAAA,CAAAJ,GAAA,YAAAG,KAAA,CAAAX,GAAA,CAAAQ,GAAA,SAAAK,MAAA,WAAAC,qBAAA,GAAAzB,MAAA,CAAAS,cAAA,IAAAT,MAAA,CAAA0B,wBAAA,WAAAvB,GAAA,IAAAgB,GAAA,QAAAhB,GAAA,kBAAAH,MAAA,CAAAI,SAAA,CAAAC,cAAA,CAAAC,IAAA,CAAAa,GAAA,EAAAhB,GAAA,SAAAwB,IAAA,GAAAF,qBAAA,GAAAzB,MAAA,CAAA0B,wBAAA,CAAAP,GAAA,EAAAhB,GAAA,cAAAwB,IAAA,KAAAA,IAAA,CAAAhB,GAAA,IAAAgB,IAAA,CAAAC,GAAA,KAAA5B,MAAA,CAAAS,cAAA,CAAAe,MAAA,EAAArB,GAAA,EAAAwB,IAAA,YAAAH,MAAA,CAAArB,GAAA,IAAAgB,GAAA,CAAAhB,GAAA,SAAAqB,MAAA,cAAAL,GAAA,MAAAG,KAAA,IAAAA,KAAA,CAAAM,GAAA,CAAAT,GAAA,EAAAK,MAAA,YAAAA,MAAA"}
|
|
@@ -1,12 +1,12 @@
|
|
|
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
|
-
import
|
|
3
|
-
import { sizeStyles } from '@os-design/styles';
|
|
4
|
-
import { omitEmotionProps } from '@os-design/utils';
|
|
2
|
+
import { css } from '@emotion/react';
|
|
5
3
|
import styled from '@emotion/styled';
|
|
6
|
-
import { clr, ThemeOverrider, useTheme } from '@os-design/theming';
|
|
7
4
|
import { Image } from '@os-design/core';
|
|
8
|
-
import { css } from '@emotion/react';
|
|
9
5
|
import { m } from '@os-design/media';
|
|
6
|
+
import { sizeStyles } from '@os-design/styles';
|
|
7
|
+
import { clr, ThemeOverrider, useTheme } from '@os-design/theming';
|
|
8
|
+
import { omitEmotionProps } from '@os-design/utils';
|
|
9
|
+
import React, { forwardRef } from 'react';
|
|
10
10
|
const BG_IMAGE_CLASS_NAME = 'section-bg-image';
|
|
11
11
|
const hasBgStyles = p => p.hasBg && css`
|
|
12
12
|
& > *:not(.${BG_IMAGE_CLASS_NAME}) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["
|
|
1
|
+
{"version":3,"file":"index.js","names":["css","styled","Image","m","sizeStyles","clr","ThemeOverrider","useTheme","omitEmotionProps","React","forwardRef","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","createElement","_extends","url","cover","filter","i","join","activeTheme","displayName"],"sources":["../../../src/Section/index.tsx"],"sourcesContent":["import { css } from '@emotion/react';\n\nimport styled from '@emotion/styled';\n\nimport { Image, ImageProps } from '@os-design/core';\n\nimport { m } from '@os-design/media';\nimport { sizeStyles, WithSize } from '@os-design/styles';\nimport { clr, ThemeOverrider, useTheme } from '@os-design/theming';\nimport { omitEmotionProps } from '@os-design/utils';\nimport React, { forwardRef } from 'react';\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,SAASA,GAAG,QAAQ,gBAAgB;AAEpC,OAAOC,MAAM,MAAM,iBAAiB;AAEpC,SAASC,KAAK,QAAoB,iBAAiB;AAEnD,SAASC,CAAC,QAAQ,kBAAkB;AACpC,SAASC,UAAU,QAAkB,mBAAmB;AACxD,SAASC,GAAG,EAAEC,cAAc,EAAEC,QAAQ,QAAQ,oBAAoB;AAClE,SAASC,gBAAgB,QAAQ,kBAAkB;AACnD,OAAOC,KAAK,IAAIC,UAAU,QAAQ,OAAO;AA0BzC,MAAMC,mBAAmB,GAAG,kBAAkB;AAE9C,MAAMC,WAAW,GAAIC,CAAC,IACpBA,CAAC,CAACC,KAAK,IACPd,GAAI;AACN,iBAAiBW,mBAAoB;AACrC;AACA;AACA,GAAG;AAKH,MAAMI,SAAS,GAAGd,MAAM,CACtB,SAAS,EACTO,gBAAgB,CAAC,OAAO,EAAE,MAAM,CAClC,CAAkB;AAClB;AACA;AACA;AACA;AACA;AACA;AACA,aAAcK,CAAC,IAAKA,CAAC,CAACG,KAAK,CAACC,sBAAuB;AACnD,MAAOJ,CAAC,IAAKA,CAAC,CAACG,KAAK,CAACE,wBAAwB,CAAC,CAAC,CAAE;AACjD,IAAIf,CAAC,CAACgB,GAAG,CAACC,EAAG;AACb,eAAgBP,CAAC,IAAKA,CAAC,CAACG,KAAK,CAACC,sBAAuB;AACrD,QAASJ,CAAC,IAAKA,CAAC,CAACG,KAAK,CAACE,wBAAwB,CAAC,CAAC,CAAE;AACnD;AACA;AACA,WAAYL,CAAC,IAAKR,GAAG,CAACQ,CAAC,CAACG,KAAK,CAACK,SAAS,CAAE;AACzC;AACA,IAAIT,WAAY;AAChB,IAAIR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,KAAM;IACXgB,KAAK;IACLR,SAAS,EAAE,CAACC,WAAW,EAAE3B,mBAAmB,CAAC,CAC1CmC,MAAM,CAAEC,CAAC,IAAKA,CAAC,CAAC,CAChBC,IAAI,CAAC,GAAG;EAAE,GACTT,WAAW,CAChB,CAEM,CACZ;EAED,IAAI,CAACV,KAAK,EAAE,OAAOY,OAAO;EAC1B,oBACEhC,KAAA,CAAAiC,aAAA,CAACpC,cAAc;IAAC2C,WAAW,EAAC,MAAM;IAACT,SAAS,EAAEA;EAAU,GACrDC,OACa,CAAC;AAErB,CACF,CAAC;AAEDb,OAAO,CAACsB,WAAW,GAAG,SAAS;AAE/B,eAAetB,OAAO"}
|
|
@@ -1,10 +1,10 @@
|
|
|
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
|
-
import React, { forwardRef } from 'react';
|
|
3
|
-
import styled from '@emotion/styled';
|
|
4
2
|
import { css } from '@emotion/react';
|
|
5
|
-
import
|
|
3
|
+
import styled from '@emotion/styled';
|
|
6
4
|
import { m } from '@os-design/media';
|
|
7
5
|
import { clr } from '@os-design/theming';
|
|
6
|
+
import { omitEmotionProps } from '@os-design/utils';
|
|
7
|
+
import React, { forwardRef } from 'react';
|
|
8
8
|
import Section from '../Section';
|
|
9
9
|
const containerHasMediaStyles = p => p.hasMedia && css`
|
|
10
10
|
display: grid;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["
|
|
1
|
+
{"version":3,"file":"index.js","names":["css","styled","m","clr","omitEmotionProps","React","forwardRef","Section","containerHasMediaStyles","p","hasMedia","theme","sectionFeatureRowGap","min","md","sectionFeatureMediaWidthPercent","sectionFeatureContentMaxWidth","sectionFeatureColumnGapPercent","containerNotHasMediaStyles","Container","colorText","Content","div","Media","sectionHasMediaStyles","StyledSection","SectionFeature","media","children","rest","ref","createElement","_extends","displayName"],"sources":["../../../src/SectionFeature/index.tsx"],"sourcesContent":["import { css } from '@emotion/react';\n\nimport styled from '@emotion/styled';\n\nimport { m } from '@os-design/media';\nimport { clr } from '@os-design/theming';\nimport { omitEmotionProps } from '@os-design/utils';\nimport React, { forwardRef } from 'react';\n\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,SAASA,GAAG,QAAQ,gBAAgB;AAEpC,OAAOC,MAAM,MAAM,iBAAiB;AAEpC,SAASC,CAAC,QAAQ,kBAAkB;AACpC,SAASC,GAAG,QAAQ,oBAAoB;AACxC,SAASC,gBAAgB,QAAQ,kBAAkB;AACnD,OAAOC,KAAK,IAAIC,UAAU,QAAQ,OAAO;AAEzC,OAAOC,OAAO,MAAwB,YAAY;AAUlD,MAAMC,uBAAuB,GAAIC,CAAC,IAChCA,CAAC,CAACC,QAAQ,IACVV,GAAI;AACN;AACA;AACA;AACA;AACA;AACA,oBAAoBS,CAAC,CAACE,KAAK,CAACC,oBAAqB;AACjD;AACA,MAAMV,CAAC,CAACW,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,0BAA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AAQ,EAAE,CAAC,CAACiB;AAAM,gBAC3BtB,KAAA,CAAA0B,aAAA,CAACV,OAAO,QAAEO,QAAkB,CAAC,EAC5BD,KAAK,iBAAItB,KAAA,CAAA0B,aAAA,CAACR,KAAK,QAAEI,KAAa,CACtB,CACE,CAEnB,CAAC;AAEDD,cAAc,CAACO,WAAW,GAAG,gBAAgB;AAE7C,eAAeP,cAAc"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { WithSize } from '@os-design/styles';
|
|
3
1
|
import { ImageProps } from '@os-design/core';
|
|
2
|
+
import { WithSize } from '@os-design/styles';
|
|
3
|
+
import React from 'react';
|
|
4
4
|
type JsxSectionProps = Omit<JSX.IntrinsicElements['section'], 'ref'>;
|
|
5
5
|
export interface SectionProps extends JsxSectionProps, WithSize {
|
|
6
6
|
bgUrl?: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Section/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/Section/index.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAS,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAGpD,OAAO,EAAc,QAAQ,EAAE,MAAM,mBAAmB,CAAC;AAGzD,OAAO,KAAqB,MAAM,OAAO,CAAC;AAE1C,KAAK,eAAe,GAAG,IAAI,CAAC,GAAG,CAAC,iBAAiB,CAAC,SAAS,CAAC,EAAE,KAAK,CAAC,CAAC;AACrE,MAAM,WAAW,YAAa,SAAQ,eAAe,EAAE,QAAQ;IAK7D,KAAK,CAAC,EAAE,MAAM,CAAC;IAKf,OAAO,CAAC,EAAE,IAAI,CAAC,UAAU,EAAE,KAAK,GAAG,OAAO,CAAC,CAAC;IAK5C,YAAY,CAAC,EAAE,OAAO,CAAC;IAKvB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AA0ED,QAAA,MAAM,OAAO,kFA2CZ,CAAC;AAIF,eAAe,OAAO,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/SectionFeature/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/SectionFeature/index.tsx"],"names":[],"mappings":"AAOA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAE1C,OAAgB,EAAE,YAAY,EAAE,MAAM,YAAY,CAAC;AAEnD,MAAM,WAAW,mBAAoB,SAAQ,YAAY;IAKvD,KAAK,CAAC,EAAE,KAAK,CAAC,YAAY,CAAC;CAC5B;AAgFD,QAAA,MAAM,cAAc,yFASnB,CAAC;AAIF,eAAe,cAAc,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@os-design/website",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.200",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"repository": "git@gitlab.com:os-team/libs/os-design.git",
|
|
6
6
|
"main": "dist/cjs/index.js",
|
|
@@ -29,16 +29,16 @@
|
|
|
29
29
|
"access": "public"
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@os-design/core": "^1.0.
|
|
32
|
+
"@os-design/core": "^1.0.198",
|
|
33
33
|
"@os-design/media": "^1.0.18",
|
|
34
|
-
"@os-design/styles": "^1.0.
|
|
35
|
-
"@os-design/theming": "^1.0.
|
|
36
|
-
"@os-design/utils": "^1.0.
|
|
34
|
+
"@os-design/styles": "^1.0.44",
|
|
35
|
+
"@os-design/theming": "^1.0.42",
|
|
36
|
+
"@os-design/utils": "^1.0.60"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
39
|
"@emotion/react": ">=11",
|
|
40
40
|
"@emotion/styled": ">=11",
|
|
41
|
-
"@os-design/icons": "^1.0.
|
|
41
|
+
"@os-design/icons": "^1.0.47"
|
|
42
42
|
},
|
|
43
43
|
"peerDependencies": {
|
|
44
44
|
"@emotion/react": ">=11",
|
|
@@ -46,5 +46,5 @@
|
|
|
46
46
|
"react": ">=18",
|
|
47
47
|
"react-dom": ">=18"
|
|
48
48
|
},
|
|
49
|
-
"gitHead": "
|
|
49
|
+
"gitHead": "8791b7a1da0d71fb3e47d0df630e835c8221cfa9"
|
|
50
50
|
}
|