From 5ce6d1b68deb8e762f5040ba7c7889b4d62c3a33 Mon Sep 17 00:00:00 2001 From: douara Date: Wed, 1 Jan 2025 15:21:29 +0800 Subject: [PATCH] Added full layout example --- .../assets/css/src/scss/_utils/_tokens.scss | 2 +- .../setting-block/src/setting-block.types.ts | 2 +- .../ui/setting-block/stories/tabs/TabCode.mdx | 12 +++++++ .../stories/tabs/TabExamples.mdx | 34 +++++++++++++++++++ 4 files changed, 48 insertions(+), 2 deletions(-) diff --git a/packages/assets/css/src/scss/_utils/_tokens.scss b/packages/assets/css/src/scss/_utils/_tokens.scss index 9e2acbe19..2e4c397ed 100644 --- a/packages/assets/css/src/scss/_utils/_tokens.scss +++ b/packages/assets/css/src/scss/_utils/_tokens.scss @@ -1,6 +1,6 @@ // Do not edit directly -// Generated on Thu, 26 Dec 2024 13:45:21 GMT +// Generated on Tue, 31 Dec 2024 06:13:16 GMT $accordion-border-radius-sm: 10px; $advanced-banner-background: linear-gradient(90deg, #222 0%, #383323 48.96%, #514524 100%); diff --git a/packages/ui/setting-block/src/setting-block.types.ts b/packages/ui/setting-block/src/setting-block.types.ts index 719171426..79e41889e 100644 --- a/packages/ui/setting-block/src/setting-block.types.ts +++ b/packages/ui/setting-block/src/setting-block.types.ts @@ -83,7 +83,7 @@ interface SettingBlockProps actions?: React.ReactNode /** - * Setting block actions + * Applies a style to hide overflowing content. */ overflowHidden?: boolean } diff --git a/packages/ui/setting-block/stories/tabs/TabCode.mdx b/packages/ui/setting-block/stories/tabs/TabCode.mdx index 264835fbc..2baff1ab7 100644 --- a/packages/ui/setting-block/stories/tabs/TabCode.mdx +++ b/packages/ui/setting-block/stories/tabs/TabCode.mdx @@ -50,6 +50,18 @@ import { Section, Row, Col, Table, List, Code, Tag, PackageInstallGuide, PropSec Optional description for the option + + Indicates whether this setting block is for Pro users. + + + + Set this to true if you want to use the full width layout variation + + + + Applies a style to hide overflowing content + + The body content of the option diff --git a/packages/ui/setting-block/stories/tabs/TabExamples.mdx b/packages/ui/setting-block/stories/tabs/TabExamples.mdx index 0cd4c9a5b..d9e98c2cf 100644 --- a/packages/ui/setting-block/stories/tabs/TabExamples.mdx +++ b/packages/ui/setting-block/stories/tabs/TabExamples.mdx @@ -48,6 +48,17 @@ export const proExample = dedent` ` +export const fullLayout = dedent` + + Body content here. This section contains valuable information designed to keep you informed and engaged. Take your time to read through and discover everything it offers. + Explore additional insights below to enrich your understanding further. + +` +

Below is a general example of the Setting Block component

@@ -78,6 +89,29 @@ export const proExample = dedent` {generalExample}
+ +
+

+ An example with a full layout setting block +

+ +
+
+ + Body content here. This section contains valuable information designed to keep you informed and engaged. Take your time to read through and discover everything it offers. + Explore additional insights below to enrich your understanding further. + +
+
+
+ {proExample} +
+ +

Set the prop isPro=\{true\} to change the variation to the Pro variation