@beehexa/design-rules 0.0.0-stage → 2611.3.2
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/README.md +56 -2
- package/dist/AGENTS.md +24 -0
- package/dist/catalog.json +1814 -0
- package/dist/docs/public/_redirects +7 -0
- package/dist/docs/public/apple-touch-icon.png +0 -0
- package/dist/docs/public/brand/logos/app/apple-touch-icon.png +0 -0
- package/dist/docs/public/brand/logos/app/avatar-800.png +0 -0
- package/dist/docs/public/brand/logos/app/icon-192.png +0 -0
- package/dist/docs/public/brand/logos/app/icon-512.png +0 -0
- package/dist/docs/public/brand/logos/app/icon-maskable-512.png +0 -0
- package/dist/docs/public/brand/logos/archive/d-550/beehexa-horizontal-1-light.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/beehexa-horizontal-2-dark.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/beehexa-horizontal-3-white.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/beehexa-horizontal-4-graphite.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/hexasync-horizontal-1-light.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/hexasync-horizontal-2-dark.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/hexasync-horizontal-3-white.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/hexasync-horizontal-4-graphite.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/beehexa-d-550-dark.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/beehexa-d-550-light.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/beehexa-design-d-550-dark.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/beehexa-design-d-550-light.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/hexasync-d-550-dark.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/hexasync-d-550-light.svg +1 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/png/beehexa-design-d-550-dark@3x.png +0 -0
- package/dist/docs/public/brand/logos/archive/d-550/ui/png/beehexa-design-d-550-light@3x.png +0 -0
- package/dist/docs/public/brand/logos/beehexa-logo.zip +0 -0
- package/dist/docs/public/brand/logos/fig/anatomy-en.png +0 -0
- package/dist/docs/public/brand/logos/fig/anatomy-vi.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-dark-12.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-dark-14.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-dark-28.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-dark-32.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-dark-56.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-graphite-28.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-graphite-32.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-14.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-21.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-22.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-24.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-28.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-32.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-36-7c3aed7c3aed.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-36-swap.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-36.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-light-56.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-white-20.png +0 -0
- package/dist/docs/public/brand/logos/fig/beehexa-white-32.png +0 -0
- package/dist/docs/public/brand/logos/fig/clearspace.png +0 -0
- package/dist/docs/public/brand/logos/fig/construction-en.png +0 -0
- package/dist/docs/public/brand/logos/fig/construction-vi.png +0 -0
- package/dist/docs/public/brand/logos/fig/container-en.png +0 -0
- package/dist/docs/public/brand/logos/fig/container-vi.png +0 -0
- package/dist/docs/public/brand/logos/fig/hexasync-dark-20.png +0 -0
- package/dist/docs/public/brand/logos/fig/hexasync-dark-28.png +0 -0
- package/dist/docs/public/brand/logos/fig/hexasync-dark-48.png +0 -0
- package/dist/docs/public/brand/logos/fig/hexasync-light-19.png +0 -0
- package/dist/docs/public/brand/logos/fig/hexasync-light-28.png +0 -0
- package/dist/docs/public/brand/logos/fig/hexasync-light-48.png +0 -0
- package/dist/docs/public/brand/logos/fig/icon-graphite-14.png +0 -0
- package/dist/docs/public/brand/logos/fig/icon-graphite-16.png +0 -0
- package/dist/docs/public/brand/logos/fig/icon-light-16.png +0 -0
- package/dist/docs/public/brand/logos/fig/icon-light-24.png +0 -0
- package/dist/docs/public/brand/logos/fig/icon-light-48.png +0 -0
- package/dist/docs/public/brand/logos/fig/icon-light-92.png +0 -0
- package/dist/docs/public/brand/logos/fig/meaning-bee-en.png +0 -0
- package/dist/docs/public/brand/logos/fig/meaning-bee-vi.png +0 -0
- package/dist/docs/public/brand/logos/fig/meaning-outline-en.png +0 -0
- package/dist/docs/public/brand/logos/fig/meaning-outline-vi.png +0 -0
- package/dist/docs/public/brand/logos/fig/meaning-stack-en.png +0 -0
- package/dist/docs/public/brand/logos/fig/meaning-stack-vi.png +0 -0
- package/dist/docs/public/brand/logos/fig/misuse-serif.png +0 -0
- package/dist/docs/public/brand/logos/icon/beehexa-icon-graphite.svg +1 -0
- package/dist/docs/public/brand/logos/icon/beehexa-icon-white.svg +1 -0
- package/dist/docs/public/brand/logos/icon/beehexa-icon-yellow.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/beehexa-horizontal-1-light.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/beehexa-horizontal-2-dark.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/beehexa-horizontal-3-white.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/beehexa-horizontal-4-graphite.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/hexasync-horizontal-1-light.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/hexasync-horizontal-2-dark.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/hexasync-horizontal-3-white.svg +1 -0
- package/dist/docs/public/brand/logos/lockups/hexasync-horizontal-4-graphite.svg +1 -0
- package/dist/docs/public/brand/logos/ui/beehexa-dark.svg +1 -0
- package/dist/docs/public/brand/logos/ui/beehexa-design-dark.svg +1 -0
- package/dist/docs/public/brand/logos/ui/beehexa-design-light.svg +1 -0
- package/dist/docs/public/brand/logos/ui/beehexa-icon-yellow.svg +1 -0
- package/dist/docs/public/brand/logos/ui/beehexa-light.svg +1 -0
- package/dist/docs/public/brand/logos/ui/hexasync-dark.svg +1 -0
- package/dist/docs/public/brand/logos/ui/hexasync-light.svg +1 -0
- package/dist/docs/public/brand/logos/ui/png/beehexa-design-dark@3x.png +0 -0
- package/dist/docs/public/brand/logos/ui/png/beehexa-design-light@3x.png +0 -0
- package/dist/docs/public/favicon.ico +0 -0
- package/dist/docs/public/favicon.svg +1 -0
- package/dist/docs/public/fonts/LICENSE-Inter.txt +93 -0
- package/dist/docs/public/fonts/LICENSE-JetBrainsMono.txt +93 -0
- package/dist/docs/public/fonts/inter-latin-ext-opsz-wght-italic.woff2 +0 -0
- package/dist/docs/public/fonts/inter-latin-ext-opsz-wght-normal.woff2 +0 -0
- package/dist/docs/public/fonts/inter-latin-opsz-wght-italic.woff2 +0 -0
- package/dist/docs/public/fonts/inter-latin-opsz-wght-normal.woff2 +0 -0
- package/dist/docs/public/fonts/inter-vietnamese-opsz-wght-italic.woff2 +0 -0
- package/dist/docs/public/fonts/inter-vietnamese-opsz-wght-normal.woff2 +0 -0
- package/dist/docs/public/fonts/jetbrains-mono-latin-ext-wght-normal.woff2 +0 -0
- package/dist/docs/public/fonts/jetbrains-mono-latin-wght-normal.woff2 +0 -0
- package/dist/docs/public/fonts/jetbrains-mono-vietnamese-wght-normal.woff2 +0 -0
- package/dist/docs/public/icon-192.png +0 -0
- package/dist/docs/public/icon-512.png +0 -0
- package/dist/docs/public/icon-maskable-512.png +0 -0
- package/dist/docs/public/robots.txt +4 -0
- package/dist/docs/public/site.webmanifest +21 -0
- package/dist/docs/scripts/color-pairs.mjs +46 -0
- package/dist/docs/scripts/contrast-exceptions.mjs +6 -0
- package/dist/docs/scripts/token-utils.d.mts +26 -0
- package/dist/docs/scripts/token-utils.mjs +114 -0
- package/dist/docs/src/brand/Beehexa-brandguide-full-mar12.pdf +0 -0
- package/dist/docs/src/brand/color+typoDirections.pdf +0 -0
- package/dist/docs/src/brand/structure-proposal.md +227 -0
- package/dist/docs/src/components/ChildPages.astro +25 -0
- package/dist/docs/src/components/CodeExample.astro +18 -0
- package/dist/docs/src/components/ColorDemo.astro +794 -0
- package/dist/docs/src/components/ColorExample.astro +32 -0
- package/dist/docs/src/components/ColorSwatch.astro +20 -0
- package/dist/docs/src/components/ComponentTabs.astro +21 -0
- package/dist/docs/src/components/DocsFooter.astro +25 -0
- package/dist/docs/src/components/HelpOptions.astro +20 -0
- package/dist/docs/src/components/IconBrowser.astro +257 -0
- package/dist/docs/src/components/IconDemo.astro +185 -0
- package/dist/docs/src/components/InDevelopment.astro +29 -0
- package/dist/docs/src/components/LayoutDemo.astro +384 -0
- package/dist/docs/src/components/Logo.astro +25 -0
- package/dist/docs/src/components/PhaseTable.astro +22 -0
- package/dist/docs/src/components/RoleGuides.astro +48 -0
- package/dist/docs/src/components/ShapeDemo.astro +239 -0
- package/dist/docs/src/components/ShapePin.astro +22 -0
- package/dist/docs/src/components/Sidebar.astro +206 -0
- package/dist/docs/src/components/SiteHeader.astro +211 -0
- package/dist/docs/src/components/SpacingDemo.astro +172 -0
- package/dist/docs/src/components/StatusBadge.astro +22 -0
- package/dist/docs/src/components/SystemAreas.astro +29 -0
- package/dist/docs/src/components/TableOfContents.astro +47 -0
- package/dist/docs/src/components/TokenTable.astro +40 -0
- package/dist/docs/src/components/TypeDemo.astro +249 -0
- package/dist/docs/src/components/logos/Fig.astro +28 -0
- package/dist/docs/src/components/logos/LogoAnatomy.astro +101 -0
- package/dist/docs/src/components/logos/LogoClearSpace.astro +81 -0
- package/dist/docs/src/components/logos/LogoColourVersions.astro +45 -0
- package/dist/docs/src/components/logos/LogoConstruction.astro +84 -0
- package/dist/docs/src/components/logos/LogoContainer.astro +84 -0
- package/dist/docs/src/components/logos/LogoHero.astro +42 -0
- package/dist/docs/src/components/logos/LogoInUse.astro +197 -0
- package/dist/docs/src/components/logos/LogoMeanings.astro +75 -0
- package/dist/docs/src/components/logos/LogoMinSize.astro +55 -0
- package/dist/docs/src/components/logos/LogoMistakes.astro +109 -0
- package/dist/docs/src/components/logos/LogoMisuse.astro +96 -0
- package/dist/docs/src/components/logos/LogoPair.astro +26 -0
- package/dist/docs/src/components/logos/LogoSvg.astro +68 -0
- package/dist/docs/src/content/components/button/accessibility.mdx +18 -0
- package/dist/docs/src/content/components/button/changelog.mdx +6 -0
- package/dist/docs/src/content/components/button/code.mdx +27 -0
- package/dist/docs/src/content/components/button/examples.mdx +21 -0
- package/dist/docs/src/content/components/button/meta.json +5 -0
- package/dist/docs/src/content/components/button/usage.mdx +18 -0
- package/dist/docs/src/content/foundations/guidelines/accessibility.mdx +19 -0
- package/dist/docs/src/content/foundations/guidelines/content.mdx +25 -0
- package/dist/docs/src/content/foundations/index.mdx +9 -0
- package/dist/docs/src/content/foundations/styles/border.mdx +89 -0
- package/dist/docs/src/content/foundations/styles/color/accessibility.mdx +32 -0
- package/dist/docs/src/content/foundations/styles/color/dark-mode.mdx +22 -0
- package/dist/docs/src/content/foundations/styles/color/index.mdx +65 -0
- package/dist/docs/src/content/foundations/styles/color/palette.mdx +57 -0
- package/dist/docs/src/content/foundations/styles/color/tokens.mdx +55 -0
- package/dist/docs/src/content/foundations/styles/color/usage.mdx +111 -0
- package/dist/docs/src/content/foundations/styles/data-visualization.mdx +11 -0
- package/dist/docs/src/content/foundations/styles/elevation.mdx +12 -0
- package/dist/docs/src/content/foundations/styles/icons/accessibility.mdx +72 -0
- package/dist/docs/src/content/foundations/styles/icons/code.mdx +171 -0
- package/dist/docs/src/content/foundations/styles/icons/index.mdx +62 -0
- package/dist/docs/src/content/foundations/styles/icons/library.mdx +19 -0
- package/dist/docs/src/content/foundations/styles/icons/usage.mdx +100 -0
- package/dist/docs/src/content/foundations/styles/illustration.mdx +9 -0
- package/dist/docs/src/content/foundations/styles/interaction-states.mdx +49 -0
- package/dist/docs/src/content/foundations/styles/layout/app-frame.mdx +81 -0
- package/dist/docs/src/content/foundations/styles/layout/breakpoints.mdx +56 -0
- package/dist/docs/src/content/foundations/styles/layout/grid.mdx +87 -0
- package/dist/docs/src/content/foundations/styles/layout/index.mdx +24 -0
- package/dist/docs/src/content/foundations/styles/layout/overlays.mdx +45 -0
- package/dist/docs/src/content/foundations/styles/layout/page-widths.mdx +38 -0
- package/dist/docs/src/content/foundations/styles/logos/downloads-and-terms.mdx +65 -0
- package/dist/docs/src/content/foundations/styles/logos/index.mdx +64 -0
- package/dist/docs/src/content/foundations/styles/logos/placement-and-containers.mdx +96 -0
- package/dist/docs/src/content/foundations/styles/logos/product-logos.mdx +56 -0
- package/dist/docs/src/content/foundations/styles/logos/using-the-logo.mdx +70 -0
- package/dist/docs/src/content/foundations/styles/motion.mdx +11 -0
- package/dist/docs/src/content/foundations/styles/opacity.mdx +9 -0
- package/dist/docs/src/content/foundations/styles/radius.mdx +98 -0
- package/dist/docs/src/content/foundations/styles/size-and-density.mdx +41 -0
- package/dist/docs/src/content/foundations/styles/spacing.mdx +70 -0
- package/dist/docs/src/content/foundations/styles/typography/code.mdx +53 -0
- package/dist/docs/src/content/foundations/styles/typography/index.mdx +58 -0
- package/dist/docs/src/content/foundations/styles/typography/usage.mdx +144 -0
- package/dist/docs/src/content/foundations/styles/typography/vietnamese.mdx +46 -0
- package/dist/docs/src/content/foundations/styles/z-index.mdx +9 -0
- package/dist/docs/src/content/foundations/tokens/all-tokens.mdx +36 -0
- package/dist/docs/src/content/foundations/tokens/index.mdx +27 -0
- package/dist/docs/src/content/get-started/content.mdx +14 -0
- package/dist/docs/src/content/get-started/design.mdx +30 -0
- package/dist/docs/src/content/get-started/develop.mdx +59 -0
- package/dist/docs/src/content/get-started/get-help.mdx +19 -0
- package/dist/docs/src/content/get-started/index.mdx +50 -0
- package/dist/docs/src/content/news/2026-10-16-site-structure.md +15 -0
- package/dist/docs/src/content/news/2026-10-20-docs-site.md +13 -0
- package/dist/docs/src/content/release-phases/index.mdx +12 -0
- package/dist/docs/src/content/tools/ai-agents.mdx +49 -0
- package/dist/docs/src/content/tools/ant-design-vue-theme.mdx +138 -0
- package/dist/docs/src/content/tools/eslint.mdx +15 -0
- package/dist/docs/src/content/tools/index.mdx +7 -0
- package/dist/docs/src/content/tools/stylelint.mdx +19 -0
- package/dist/docs/src/content-vi/foundations/styles/border.mdx +89 -0
- package/dist/docs/src/content-vi/foundations/styles/color/accessibility.mdx +32 -0
- package/dist/docs/src/content-vi/foundations/styles/color/dark-mode.mdx +22 -0
- package/dist/docs/src/content-vi/foundations/styles/color/index.mdx +65 -0
- package/dist/docs/src/content-vi/foundations/styles/color/palette.mdx +57 -0
- package/dist/docs/src/content-vi/foundations/styles/color/tokens.mdx +55 -0
- package/dist/docs/src/content-vi/foundations/styles/color/usage.mdx +111 -0
- package/dist/docs/src/content-vi/foundations/styles/data-visualization.mdx +11 -0
- package/dist/docs/src/content-vi/foundations/styles/icons/accessibility.mdx +72 -0
- package/dist/docs/src/content-vi/foundations/styles/icons/code.mdx +170 -0
- package/dist/docs/src/content-vi/foundations/styles/icons/index.mdx +62 -0
- package/dist/docs/src/content-vi/foundations/styles/icons/library.mdx +19 -0
- package/dist/docs/src/content-vi/foundations/styles/icons/usage.mdx +100 -0
- package/dist/docs/src/content-vi/foundations/styles/illustration.mdx +9 -0
- package/dist/docs/src/content-vi/foundations/styles/interaction-states.mdx +49 -0
- package/dist/docs/src/content-vi/foundations/styles/layout/app-frame.mdx +77 -0
- package/dist/docs/src/content-vi/foundations/styles/layout/breakpoints.mdx +56 -0
- package/dist/docs/src/content-vi/foundations/styles/layout/grid.mdx +87 -0
- package/dist/docs/src/content-vi/foundations/styles/layout/index.mdx +24 -0
- package/dist/docs/src/content-vi/foundations/styles/layout/page-widths.mdx +34 -0
- package/dist/docs/src/content-vi/foundations/styles/logos/downloads-and-terms.mdx +65 -0
- package/dist/docs/src/content-vi/foundations/styles/logos/index.mdx +64 -0
- package/dist/docs/src/content-vi/foundations/styles/logos/placement-and-containers.mdx +96 -0
- package/dist/docs/src/content-vi/foundations/styles/logos/product-logos.mdx +56 -0
- package/dist/docs/src/content-vi/foundations/styles/logos/using-the-logo.mdx +70 -0
- package/dist/docs/src/content-vi/foundations/styles/opacity.mdx +9 -0
- package/dist/docs/src/content-vi/foundations/styles/radius.mdx +98 -0
- package/dist/docs/src/content-vi/foundations/styles/size-and-density.mdx +41 -0
- package/dist/docs/src/content-vi/foundations/styles/spacing.mdx +70 -0
- package/dist/docs/src/content-vi/foundations/styles/typography/code.mdx +53 -0
- package/dist/docs/src/content-vi/foundations/styles/typography/index.mdx +58 -0
- package/dist/docs/src/content-vi/foundations/styles/typography/usage.mdx +144 -0
- package/dist/docs/src/content-vi/foundations/styles/typography/vietnamese.mdx +46 -0
- package/dist/docs/src/content-vi/foundations/styles/z-index.mdx +9 -0
- package/dist/docs/src/content.config.ts +68 -0
- package/dist/docs/src/lib/brand.ts +57 -0
- package/dist/docs/src/lib/contrast.ts +34 -0
- package/dist/docs/src/lib/i18n.ts +152 -0
- package/dist/docs/src/lib/icons.ts +46 -0
- package/dist/docs/src/lib/logo-geometry.ts +30 -0
- package/dist/docs/src/lib/lucide-categories.json +1 -0
- package/dist/docs/src/lib/lucide-data.ts +40 -0
- package/dist/docs/src/lib/navigation.ts +222 -0
- package/dist/docs/src/lib/release-phases.ts +10 -0
- package/dist/docs/src/lib/routes.ts +40 -0
- package/dist/docs/src/lib/token-descriptions-vi.ts +40 -0
- package/dist/docs/src/lib/tokens.ts +67 -0
- package/dist/docs/src/lib/tri-grid.ts +28 -0
- package/dist/docs/src/styles/chrome.css +122 -0
- package/dist/docs/src/styles/color.css +270 -0
- package/dist/docs/src/styles/docs.css +323 -0
- package/dist/docs/src/styles/global.css +66 -0
- package/dist/docs/src/styles/icons.css +135 -0
- package/dist/docs/src/styles/layout.css +165 -0
- package/dist/docs/src/styles/logos.css +236 -0
- package/dist/docs/src/styles/shapes.css +139 -0
- package/dist/docs/src/styles/tokens.css +461 -0
- package/dist/docs/src/styles/tokens.js +425 -0
- package/dist/docs/src/styles/typography.css +91 -0
- package/dist/docs/tokens/border.json +26 -0
- package/dist/docs/tokens/breakpoints.json +8 -0
- package/dist/docs/tokens/color.json +1350 -0
- package/dist/docs/tokens/elevation.json +26 -0
- package/dist/docs/tokens/layout.json +29 -0
- package/dist/docs/tokens/motion.json +12 -0
- package/dist/docs/tokens/radius.json +44 -0
- package/dist/docs/tokens/size.json +13 -0
- package/dist/docs/tokens/spacing.json +18 -0
- package/dist/docs/tokens/states.json +12 -0
- package/dist/docs/tokens/typography.json +220 -0
- package/dist/index.d.ts +19 -0
- package/dist/index.js +1823 -0
- package/package.json +31 -4
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
---
|
|
2
|
+
// Do and don't. Each example is the real logo with one thing done wrong.
|
|
3
|
+
// The six don'ts of the 2025 brand guide (p22), plus effects and low-contrast backgrounds.
|
|
4
|
+
import { COLORS, ICON_H, ICON_PATH, ICON_SCALE, ICON_TOP, WORDMARKS } from '../../lib/logo-geometry';
|
|
5
|
+
import { langOf } from '../../lib/i18n';
|
|
6
|
+
import LogoSvg from './LogoSvg.astro';
|
|
7
|
+
import Fig from './Fig.astro';
|
|
8
|
+
import '../../styles/logos.css';
|
|
9
|
+
|
|
10
|
+
const lang = langOf(Astro.url.pathname);
|
|
11
|
+
const iconPx = 36;
|
|
12
|
+
const s = iconPx / ICON_H;
|
|
13
|
+
// "Don't retype the name": the icon with the name set in a serif typeface.
|
|
14
|
+
const serif = [WORDMARKS.beehexa].map((word) => {
|
|
15
|
+
const m = 1 / s; // the same 1 px margin as LogoSvg
|
|
16
|
+
const w = Math.ceil((word.width + 2 * m) * s - 1e-6);
|
|
17
|
+
const h = Math.ceil((ICON_H + 2 * m) * s - 1e-6);
|
|
18
|
+
return { w, h, x: word.x, viewBox: `${-m} ${ICON_TOP - m} ${w / s} ${h / s}` };
|
|
19
|
+
});
|
|
20
|
+
const cross = '<svg viewBox="0 0 16 16" width="16" height="16" aria-hidden="true"><circle cx="8" cy="8" r="7" fill="currentColor"/><path d="M5.5 5.5l5 5m0-5l-5 5" stroke="#fff" stroke-width="1.6" stroke-linecap="round"/></svg>';
|
|
21
|
+
const check = '<svg viewBox="0 0 16 16" width="16" height="16" aria-hidden="true"><circle cx="8" cy="8" r="7" fill="currentColor"/><path d="M4.8 8.2l2.1 2.1 4.3-4.6" stroke="#fff" stroke-width="1.6" fill="none" stroke-linecap="round" stroke-linejoin="round"/></svg>';
|
|
22
|
+
|
|
23
|
+
type Case = { key: string; title: string; text: string; alt: string };
|
|
24
|
+
const C: Record<string, Case> = Object.fromEntries(
|
|
25
|
+
(lang === 'vi'
|
|
26
|
+
? [
|
|
27
|
+
['do', 'Nên', 'Dùng file gốc đúng như đã vẽ, trên nền mà phiên bản đó dành cho.', 'Đúng: lockup như bản vẽ'],
|
|
28
|
+
['stretch', 'Không kéo giãn hay ép dẹt', 'Chỉ phóng to, thu nhỏ theo đúng tỉ lệ.', 'Sai: bị kéo giãn'],
|
|
29
|
+
['recolour', 'Không đổi màu', 'Chỉ dùng một trong bốn bản màu.', 'Sai: bị đổi màu'],
|
|
30
|
+
['serif', 'Không gõ lại tên', 'Không tự gõ wordmark bằng font, kiểu chữ hay cách viết hoa khác.', 'Sai: tên gõ bằng font khác'],
|
|
31
|
+
['fade', 'Không làm mờ', 'Luôn để logo ở độ đậm đặc 100%.', 'Sai: bị làm mờ'],
|
|
32
|
+
['rotate', 'Không xoay', 'Logo luôn nằm ngang.', 'Sai: bị xoay'],
|
|
33
|
+
['swap', 'Không đổi bố cục', 'Icon trước, chữ sau, đúng khoảng cách đã vẽ. Không có bản xếp dọc.', 'Sai: chữ đứng trước icon'],
|
|
34
|
+
['effects', 'Không thêm hiệu ứng', 'Không đổ bóng, viền, phát sáng, chuyển màu hay 3D.', 'Sai: thêm đổ bóng'],
|
|
35
|
+
['contrast', 'Không đặt trên nền thiếu tương phản', 'Trên nền vàng hoặc nền rối, dùng bản xám ghi hoặc bản trắng.', 'Sai: logo màu trên nền vàng'],
|
|
36
|
+
]
|
|
37
|
+
: [
|
|
38
|
+
['do', 'Do', 'Use the master file as drawn, on a background its version was made for.', 'Correct: the lockup as drawn'],
|
|
39
|
+
['stretch', 'Don’t stretch or squash', 'Scale it in proportion only.', 'Wrong: stretched'],
|
|
40
|
+
['recolour', 'Don’t recolour', 'Use one of the four colour versions.', 'Wrong: recoloured'],
|
|
41
|
+
['serif', 'Don’t retype the name', 'Never set the wordmark in a font, case or style of your own.', 'Wrong: name set in another typeface'],
|
|
42
|
+
['fade', 'Don’t fade it', 'Keep the logo at full opacity.', 'Wrong: faded'],
|
|
43
|
+
['rotate', 'Don’t rotate', 'The logo always sits level.', 'Wrong: rotated'],
|
|
44
|
+
['swap', 'Don’t rearrange', 'Icon first, then the wordmark, at the spacing drawn. No stacked version.', 'Wrong: wordmark before the icon'],
|
|
45
|
+
['effects', 'Don’t add effects', 'No shadows, outlines, glows, gradients or 3D.', 'Wrong: drop shadow added'],
|
|
46
|
+
['contrast', 'Don’t lose the contrast', 'On yellow or busy backgrounds, use the graphite or white version.', 'Wrong: colour logo on a yellow background'],
|
|
47
|
+
]
|
|
48
|
+
).map(([key, title, text, alt]) => [key, { key, title, text, alt }]),
|
|
49
|
+
);
|
|
50
|
+
---
|
|
51
|
+
|
|
52
|
+
<div class="logo-cards misuse" style="--cols:3">
|
|
53
|
+
<div class="logo-card is-do">
|
|
54
|
+
<div class="logo-stage bg-white misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" label={C.do.alt} /></div>
|
|
55
|
+
<div class="logo-card-body"><p class="verdict verdict-do" set:html={check + C.do.title} /><p>{C.do.text}</p></div>
|
|
56
|
+
</div>
|
|
57
|
+
<div class="logo-card is-dont">
|
|
58
|
+
<div class="logo-stage bg-white misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" style="transform:scale(1.4,0.8)" label={C.stretch.alt} /></div>
|
|
59
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.stretch.title} /><p>{C.stretch.text}</p></div>
|
|
60
|
+
</div>
|
|
61
|
+
<div class="logo-card is-dont">
|
|
62
|
+
<div class="logo-stage bg-white misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" fills={['#7c3aed', '#7c3aed']} label={C.recolour.alt} /></div>
|
|
63
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.recolour.title} /><p>{C.recolour.text}</p></div>
|
|
64
|
+
</div>
|
|
65
|
+
<div class="logo-card is-dont">
|
|
66
|
+
<div class="logo-stage bg-white misuse-stage">
|
|
67
|
+
{serif.map((d) => (
|
|
68
|
+
<Fig id="misuse-serif" class={['px-center']} viewBox={d.viewBox} w={d.w} h={d.h} label={C.serif.alt}>
|
|
69
|
+
<path fill={COLORS.yellow} fill-rule="evenodd" transform={`translate(0 ${ICON_TOP}) scale(${ICON_SCALE})`} d={ICON_PATH} />
|
|
70
|
+
<text x={d.x} y="0" fill={COLORS.graphite} font-family="Georgia, 'Times New Roman', serif" font-size="1900" font-style="italic">Beehexa</text>
|
|
71
|
+
</Fig>
|
|
72
|
+
))}
|
|
73
|
+
</div>
|
|
74
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.serif.title} /><p>{C.serif.text}</p></div>
|
|
75
|
+
</div>
|
|
76
|
+
<div class="logo-card is-dont">
|
|
77
|
+
<div class="logo-stage bg-white misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" style="opacity:.35" label={C.fade.alt} /></div>
|
|
78
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.fade.title} /><p>{C.fade.text}</p></div>
|
|
79
|
+
</div>
|
|
80
|
+
<div class="logo-card is-dont">
|
|
81
|
+
<div class="logo-stage bg-white misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" style="transform:rotate(-12deg)" label={C.rotate.alt} /></div>
|
|
82
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.rotate.title} /><p>{C.rotate.text}</p></div>
|
|
83
|
+
</div>
|
|
84
|
+
<div class="logo-card is-dont">
|
|
85
|
+
<div class="logo-stage bg-white misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" swap label={C.swap.alt} /></div>
|
|
86
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.swap.title} /><p>{C.swap.text}</p></div>
|
|
87
|
+
</div>
|
|
88
|
+
<div class="logo-card is-dont">
|
|
89
|
+
<div class="logo-stage bg-white misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" style="filter:drop-shadow(3px 4px 3px rgb(0 0 0 / 45%))" label={C.effects.alt} /></div>
|
|
90
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.effects.title} /><p>{C.effects.text}</p></div>
|
|
91
|
+
</div>
|
|
92
|
+
<div class="logo-card is-dont">
|
|
93
|
+
<div class="logo-stage bg-yellow misuse-stage"><LogoSvg iconPx={iconPx} class="px-center" label={C.contrast.alt} /></div>
|
|
94
|
+
<div class="logo-card-body"><p class="verdict verdict-dont" set:html={cross + C.contrast.title} /><p>{C.contrast.text}</p></div>
|
|
95
|
+
</div>
|
|
96
|
+
</div>
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
---
|
|
2
|
+
// One lockup on a light and a dark panel, centred on whole pixels.
|
|
3
|
+
import LogoSvg from './LogoSvg.astro';
|
|
4
|
+
import { langOf } from '../../lib/i18n';
|
|
5
|
+
import '../../styles/logos.css';
|
|
6
|
+
|
|
7
|
+
interface Props {
|
|
8
|
+
kind?: 'beehexa' | 'hexasync';
|
|
9
|
+
name: string;
|
|
10
|
+
}
|
|
11
|
+
const { kind = 'beehexa', name } = Astro.props;
|
|
12
|
+
const lang = langOf(Astro.url.pathname);
|
|
13
|
+
const light = lang === 'vi' ? `Logo ${name} cho nền sáng` : `${name} logo for light backgrounds`;
|
|
14
|
+
const dark = lang === 'vi' ? `Logo ${name} cho nền tối` : `${name} logo for dark backgrounds`;
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
<div class="logo-hero-panels pair">
|
|
18
|
+
<div class="logo-stage hero-stage bg-white">
|
|
19
|
+
<LogoSvg kind={kind} version="light" iconPx={48} class="px-center hero-lg" label={light} />
|
|
20
|
+
<LogoSvg kind={kind} version="light" iconPx={28} class="px-center hero-sm" label={light} />
|
|
21
|
+
</div>
|
|
22
|
+
<div class="logo-stage hero-stage bg-graphite">
|
|
23
|
+
<LogoSvg kind={kind} version="dark" iconPx={48} class="px-center hero-lg" label={dark} />
|
|
24
|
+
<LogoSvg kind={kind} version="dark" iconPx={28} class="px-center hero-sm" label={dark} />
|
|
25
|
+
</div>
|
|
26
|
+
</div>
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
---
|
|
2
|
+
// The logo from the master geometry at a whole-pixel size, shown as a 3× PNG (see Fig.astro).
|
|
3
|
+
// The box is rounded up to whole pixels by widening the viewBox, never by scaling the artwork,
|
|
4
|
+
// so the icon keeps its exact height. Centre it with the `px-center` class (logos.css).
|
|
5
|
+
import { COLORS, ICON_H, ICON_PATH, ICON_SCALE, ICON_TOP, ICON_W, WORDMARKS, type Version } from '../../lib/logo-geometry';
|
|
6
|
+
import Fig from './Fig.astro';
|
|
7
|
+
import '../../styles/logos.css';
|
|
8
|
+
|
|
9
|
+
interface Props {
|
|
10
|
+
kind?: 'beehexa' | 'hexasync' | 'icon';
|
|
11
|
+
version?: Version | 'auto'; // auto: light on the light theme, dark on the dark theme
|
|
12
|
+
iconPx: number; // icon height in px
|
|
13
|
+
clear?: boolean; // include the clear space (1 x-height) around the logo
|
|
14
|
+
label?: string; // accessible name; empty = decorative
|
|
15
|
+
class?: string;
|
|
16
|
+
style?: string; // misuse demos: transforms and filters on the picture
|
|
17
|
+
swap?: boolean; // misuse demo: wordmark before the icon
|
|
18
|
+
fills?: [string, string]; // misuse demo: other colours for icon and text
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
const { kind = 'beehexa', version = 'light', iconPx, clear = false, label = '', class: cls, style = '', swap = false, fills: custom } = Astro.props;
|
|
22
|
+
|
|
23
|
+
const fills: Record<Version, [string, string]> = {
|
|
24
|
+
light: [COLORS.yellow, COLORS.graphite],
|
|
25
|
+
dark: [COLORS.yellow, COLORS.white],
|
|
26
|
+
white: [COLORS.white, COLORS.white],
|
|
27
|
+
graphite: [COLORS.graphite, COLORS.graphite],
|
|
28
|
+
};
|
|
29
|
+
const s = iconPx / ICON_H;
|
|
30
|
+
const CLEAR = 1056;
|
|
31
|
+
|
|
32
|
+
const figs = (() => {
|
|
33
|
+
const word = kind === 'icon' ? undefined : WORDMARKS[kind];
|
|
34
|
+
const inkW = word ? word.width : ICON_W;
|
|
35
|
+
const inkH = word ? word.height : ICON_H;
|
|
36
|
+
// Without the clear space, keep a 1 px margin: a picture cropped to the ink loses the soft
|
|
37
|
+
// edge of the icon's points and the descender of the "y" in HexaSync.
|
|
38
|
+
const pad = clear ? CLEAR : 1 / s;
|
|
39
|
+
const w = Math.ceil((inkW + 2 * pad) * s - 1e-6);
|
|
40
|
+
const h = Math.ceil((inkH + 2 * pad) * s - 1e-6);
|
|
41
|
+
const viewBox = `${-pad} ${ICON_TOP - pad} ${w / s} ${h / s}`;
|
|
42
|
+
// Misuse demo only: put the wordmark first, then the icon.
|
|
43
|
+
const wordX = swap && word ? 0 : word?.x;
|
|
44
|
+
const iconX = swap && word ? word.width - ICON_W : 0;
|
|
45
|
+
const versions = version === 'auto' ? (['light', 'dark'] as const) : [version];
|
|
46
|
+
return versions.map((v) => {
|
|
47
|
+
const [iconFill, wordFill] = custom ?? fills[v];
|
|
48
|
+
const extra = [clear && 'clear', swap && 'swap', custom && custom.join('').replace(/#/g, '')].filter(Boolean).join('-');
|
|
49
|
+
const figId = [kind, v, iconPx, extra].filter(Boolean).join('-');
|
|
50
|
+
return { v, w, h, viewBox, wordX, iconX, word, iconFill, wordFill, figId };
|
|
51
|
+
});
|
|
52
|
+
})();
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
{figs.map((f) => (
|
|
56
|
+
<Fig
|
|
57
|
+
id={f.figId}
|
|
58
|
+
w={f.w}
|
|
59
|
+
h={f.h}
|
|
60
|
+
viewBox={f.viewBox}
|
|
61
|
+
class={[cls, version === 'auto' && `logo-${f.v}`]}
|
|
62
|
+
style={style}
|
|
63
|
+
label={label}
|
|
64
|
+
>
|
|
65
|
+
<path fill={f.iconFill} fill-rule="evenodd" transform={`translate(${f.iconX} ${ICON_TOP}) scale(${ICON_SCALE})`} d={ICON_PATH} />
|
|
66
|
+
{f.word && <path fill={f.wordFill} transform={`translate(${f.wordX} 0)`} d={f.word.d} />}
|
|
67
|
+
</Fig>
|
|
68
|
+
))}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
---
|
|
2
|
+
---
|
|
3
|
+
|
|
4
|
+
## Keyboard
|
|
5
|
+
|
|
6
|
+
| Key | Action |
|
|
7
|
+
| --- | --- |
|
|
8
|
+
| <kbd>Tab</kbd> | Moves focus to the button. |
|
|
9
|
+
| <kbd>Enter</kbd> or <kbd>Space</kbd> | Activates the button. |
|
|
10
|
+
|
|
11
|
+
## Requirements
|
|
12
|
+
|
|
13
|
+
- Use a native `<button>` element. Ant Design Vue renders one.
|
|
14
|
+
- Icon-only buttons need an `aria-label`.
|
|
15
|
+
- Focus is shown with a 2 px ring in `color.border.focus`, 2 px away from the button (`border.width.focused`, `state.focus.offset`).
|
|
16
|
+
- The target is at least 24 × 24px (WCAG 2.5.8).
|
|
17
|
+
- Text and background meet 4.5:1 contrast in every state except disabled.
|
|
18
|
+
- When `loading` is set, announce the result of the action when it finishes.
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
---
|
|
2
|
+
description: Use the Ant Design Vue button with the Beehexa theme.
|
|
3
|
+
---
|
|
4
|
+
import CodeExample from '../../../components/CodeExample.astro';
|
|
5
|
+
|
|
6
|
+
## Installation
|
|
7
|
+
|
|
8
|
+
Buttons come from Ant Design Vue. Apply the [Beehexa theme](/tools/ant-design-vue-theme/) once at the root of the app.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
<CodeExample lang="vue" code={`<template>
|
|
13
|
+
<a-space>
|
|
14
|
+
<a-button>Cancel</a-button>
|
|
15
|
+
<a-button type="primary" :loading="saving" @click="save">Save changes</a-button>
|
|
16
|
+
<a-button danger>Delete integration</a-button>
|
|
17
|
+
</a-space>
|
|
18
|
+
</template>`} />
|
|
19
|
+
|
|
20
|
+
## Props
|
|
21
|
+
|
|
22
|
+
| Prop | Values | Notes |
|
|
23
|
+
| --- | --- | --- |
|
|
24
|
+
| `type` | `default`, `primary`, `link`, `text` | Use `primary` once per screen. |
|
|
25
|
+
| `danger` | `boolean` | For destructive actions. |
|
|
26
|
+
| `loading` | `boolean` | Shows a spinner and blocks repeat clicks. |
|
|
27
|
+
| `disabled` | `boolean` | Prefer explaining why an action is unavailable. |
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
---
|
|
2
|
+
---
|
|
3
|
+
import CodeExample from '../../../components/CodeExample.astro';
|
|
4
|
+
|
|
5
|
+
## Default
|
|
6
|
+
|
|
7
|
+
<CodeExample code={`<button class="bh-button" type="button">Cancel</button>`} />
|
|
8
|
+
|
|
9
|
+
## Primary
|
|
10
|
+
|
|
11
|
+
Use one primary button for the main action on a screen.
|
|
12
|
+
|
|
13
|
+
<CodeExample code={`<button class="bh-button bh-button-primary" type="button">Save changes</button>`} />
|
|
14
|
+
|
|
15
|
+
## Danger
|
|
16
|
+
|
|
17
|
+
<CodeExample code={`<button class="bh-button bh-button-danger" type="button">Delete integration</button>`} />
|
|
18
|
+
|
|
19
|
+
## Disabled
|
|
20
|
+
|
|
21
|
+
<CodeExample code={`<button class="bh-button bh-button-primary" type="button" disabled>Save changes</button>`} />
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
---
|
|
2
|
+
---
|
|
3
|
+
|
|
4
|
+
## When to use
|
|
5
|
+
|
|
6
|
+
- To trigger an action: save, submit, sync, delete.
|
|
7
|
+
- To open a dialog or start a flow.
|
|
8
|
+
|
|
9
|
+
## When not to use
|
|
10
|
+
|
|
11
|
+
- To go to another page. Use a link.
|
|
12
|
+
- For many actions in a row. Use a dropdown menu for the less common ones.
|
|
13
|
+
|
|
14
|
+
## Best practices
|
|
15
|
+
|
|
16
|
+
- Start the label with a verb and keep it short: "Sync orders".
|
|
17
|
+
- Put the primary button last in a group, on the right.
|
|
18
|
+
- Ask for confirmation before destructive actions.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Accessibility
|
|
3
|
+
description: Beehexa products meet WCAG 2.2 level AA.
|
|
4
|
+
order: 1
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Our commitment
|
|
8
|
+
|
|
9
|
+
Every Beehexa product meets [WCAG 2.2](https://www.w3.org/TR/WCAG22/) level AA. Every component page has an Accessibility tab that says how the component meets it and what product teams still need to do.
|
|
10
|
+
|
|
11
|
+
## Checklist
|
|
12
|
+
|
|
13
|
+
- **Contrast**: text has at least 4.5:1 contrast with its background, large text and UI parts at least 3:1.
|
|
14
|
+
- **Keyboard**: everything that works with a mouse works with a keyboard, in a logical order.
|
|
15
|
+
- **Focus**: keyboard focus is always visible. Use a 2 px ring in `color.border.focus`, 2 px away from the element (`border.width.focused`, `state.focus.offset`).
|
|
16
|
+
- **Target size**: pointer targets are at least 24 × 24 CSS pixels.
|
|
17
|
+
- **Labels**: every control has a visible label or an accessible name.
|
|
18
|
+
- **Motion**: respect `prefers-reduced-motion`.
|
|
19
|
+
- **Errors**: say what went wrong in text, not only with color.
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Content
|
|
3
|
+
description: How to write clear, concise and consistent product copy.
|
|
4
|
+
order: 2
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## Voice
|
|
8
|
+
|
|
9
|
+
Clear, direct and helpful. Write for busy people who manage data across many systems.
|
|
10
|
+
|
|
11
|
+
## Rules
|
|
12
|
+
|
|
13
|
+
- Use sentence case for labels, headings and buttons.
|
|
14
|
+
- Start buttons with a verb: "Save", "Sync orders", "Delete integration".
|
|
15
|
+
- Keep one name for one thing across the product.
|
|
16
|
+
- Use numerals for numbers: "3 orders failed".
|
|
17
|
+
- Avoid jargon unless your readers use it.
|
|
18
|
+
|
|
19
|
+
## Messages
|
|
20
|
+
|
|
21
|
+
| Type | Write |
|
|
22
|
+
| --- | --- |
|
|
23
|
+
| Error | What happened, why, and how to fix it. |
|
|
24
|
+
| Empty state | What will appear here and how to add the first item. |
|
|
25
|
+
| Confirmation | The action and its consequence: "Delete 3 orders? This can't be undone." |
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Foundations
|
|
3
|
+
description: Foundations create consistent user experiences. They include our design tokens, guidelines and visual styles.
|
|
4
|
+
order: 0
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
Foundations are the decisions every Beehexa interface shares. They are grouped as design tokens, guidelines and styles.
|
|
8
|
+
|
|
9
|
+
> Token values are provisional. They were taken from the current landing page while the team decides which system to base the values on.
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Border
|
|
3
|
+
description: Four border widths, the colour each one goes with, and how the focus ring is drawn.
|
|
4
|
+
order: 7
|
|
5
|
+
---
|
|
6
|
+
import ShapeDemo from '../../../components/ShapeDemo.astro';
|
|
7
|
+
import TokenTable from '../../../components/TokenTable.astro';
|
|
8
|
+
|
|
9
|
+
**Most borders are 1 px. Thicker lines mean something: selected, focused, or a status to notice.**
|
|
10
|
+
|
|
11
|
+
Border colours are colour tokens: `color.border` for dividers and cards, `color.border.bold` for the edges of inputs, checkboxes and selects. See [Tokens](/foundations/styles/color/tokens/#borders).
|
|
12
|
+
|
|
13
|
+
## The widths
|
|
14
|
+
|
|
15
|
+
<ShapeDemo kind="border-scale" />
|
|
16
|
+
|
|
17
|
+
## Examples
|
|
18
|
+
|
|
19
|
+
### `border.width.default` · 1 px
|
|
20
|
+
|
|
21
|
+
Inputs, secondary buttons, cards, tables and dividers.
|
|
22
|
+
|
|
23
|
+
<ShapeDemo kind="border-use" item="default" />
|
|
24
|
+
|
|
25
|
+
### `border.width.selected` · 2 px
|
|
26
|
+
|
|
27
|
+
The bar under a selected tab, the bar beside a selected side navigation item, and the edge of a selected card. Always with `color.border.selected`.
|
|
28
|
+
|
|
29
|
+
<ShapeDemo kind="border-use" item="selected" />
|
|
30
|
+
|
|
31
|
+
### `border.width.focused` · 2 px
|
|
32
|
+
|
|
33
|
+
The focus ring, in `color.border.focus`, drawn 2 px outside the element (`state.focus.offset`). Draw it inside, at −2 px, when a box around the element would cut it off: menu items, table cells and tabs in a scroll area.
|
|
34
|
+
|
|
35
|
+
<ShapeDemo kind="border-use" item="focused" />
|
|
36
|
+
|
|
37
|
+
### `border.width.accent` · 4 px
|
|
38
|
+
|
|
39
|
+
A status or emphasis bar on one edge: alerts and banners, a table row with an error, callouts and quotes. The box keeps its radius on all four corners and the bar follows the curve.
|
|
40
|
+
|
|
41
|
+
<ShapeDemo kind="border-use" item="accent" />
|
|
42
|
+
|
|
43
|
+
## Width and colour go together
|
|
44
|
+
|
|
45
|
+
| Width | Colour | For |
|
|
46
|
+
|---|---|---|
|
|
47
|
+
| `border.width.default` | `color.border` or `color.border.bold` | Edges and dividers |
|
|
48
|
+
| `border.width.selected` | `color.border.selected` | Selected tab, side navigation item or card |
|
|
49
|
+
| `border.width.focused` | `color.border.focus` | Keyboard focus |
|
|
50
|
+
| `border.width.accent` | `color.border.danger`, `.warning`, `.success`, `.info` or `.brand` | Status and emphasis bars |
|
|
51
|
+
|
|
52
|
+
Don't show a state with colour alone. Selected and focused also change the width.
|
|
53
|
+
|
|
54
|
+
## Do and don’t
|
|
55
|
+
|
|
56
|
+
<ShapeDemo kind="dodont" item="selected" />
|
|
57
|
+
<ShapeDemo kind="dodont" item="accent" />
|
|
58
|
+
<ShapeDemo kind="dodont" item="cards" />
|
|
59
|
+
|
|
60
|
+
## Code
|
|
61
|
+
|
|
62
|
+
```css
|
|
63
|
+
.alert {
|
|
64
|
+
position: relative;
|
|
65
|
+
overflow: hidden;
|
|
66
|
+
border: var(--bh-border-width-default) solid var(--bh-color-border);
|
|
67
|
+
border-radius: var(--bh-radius-100);
|
|
68
|
+
}
|
|
69
|
+
.alert::before {
|
|
70
|
+
content: "";
|
|
71
|
+
position: absolute;
|
|
72
|
+
inset: 0 auto 0 0;
|
|
73
|
+
width: var(--bh-border-width-accent);
|
|
74
|
+
background: var(--bh-color-border-danger);
|
|
75
|
+
}
|
|
76
|
+
:focus-visible {
|
|
77
|
+
outline: var(--bh-border-width-focused) solid var(--bh-color-border-focus);
|
|
78
|
+
outline-offset: var(--bh-state-focus-offset);
|
|
79
|
+
}
|
|
80
|
+
```
|
|
81
|
+
|
|
82
|
+
## Tokens
|
|
83
|
+
|
|
84
|
+
<TokenTable prefix="border" />
|
|
85
|
+
|
|
86
|
+
## Related
|
|
87
|
+
|
|
88
|
+
- [Radius](/foundations/styles/radius/): corner radius steps and the nesting rule.
|
|
89
|
+
- [Interaction states](/foundations/styles/interaction-states/): hover, pressed, selected and disabled.
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Accessibility
|
|
3
|
+
description: The contrast every colour pair meets, which text may sit on which background, and how it is checked.
|
|
4
|
+
order: 6
|
|
5
|
+
---
|
|
6
|
+
import ColorDemo from '../../../../components/ColorDemo.astro';
|
|
7
|
+
|
|
8
|
+
**Every text and icon token passes WCAG 2.2 AA on every background it is paired with, in light and in dark: all 386 pairs.**
|
|
9
|
+
|
|
10
|
+
## Contrast
|
|
11
|
+
|
|
12
|
+
| What | Minimum | WCAG 2.2 |
|
|
13
|
+
|---|---|---|
|
|
14
|
+
| Text | 4.5:1 | 1.4.3 |
|
|
15
|
+
| Icons, control edges, focus ring | 3:1 | 1.4.11 |
|
|
16
|
+
| Disabled controls, the yellow indicator bar, the logo | No minimum | 1.4.3 exception |
|
|
17
|
+
|
|
18
|
+
<ColorDemo kind="contrast" />
|
|
19
|
+
|
|
20
|
+
Colour is never the only signal (WCAG 1.4.1): statuses are written in words, selected items have a second cue.
|
|
21
|
+
|
|
22
|
+
## Pairing
|
|
23
|
+
|
|
24
|
+
**Text, icons and borders only go on the backgrounds listed with them.** Every pair here passes contrast in light and dark, and is checked on every build.
|
|
25
|
+
|
|
26
|
+
<ColorDemo kind="pairing" />
|
|
27
|
+
|
|
28
|
+
<ColorDemo kind="dodont" item="pairing" />
|
|
29
|
+
|
|
30
|
+
## Checked automatically
|
|
31
|
+
|
|
32
|
+
Every pair in [Pairing](#pairing) is checked automatically, in light and in dark. A text, icon or border token that falls below its minimum on any of its backgrounds is not released.
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Dark mode
|
|
3
|
+
description: How the dark theme works, what changes and what you never do in dark.
|
|
4
|
+
order: 5
|
|
5
|
+
---
|
|
6
|
+
import ColorDemo from '../../../../components/ColorDemo.astro';
|
|
7
|
+
|
|
8
|
+
**Write each token once; the theme changes the value.**
|
|
9
|
+
|
|
10
|
+
<ColorDemo kind="themes" />
|
|
11
|
+
|
|
12
|
+
## How it works
|
|
13
|
+
|
|
14
|
+
Every colour token has a light and a dark value under the same name. The theme picks the value; your code and designs name the token once. The dark values of every palette step are on [Palette](/foundations/styles/color/palette/), and every role token's are on [Tokens](/foundations/styles/color/tokens/).
|
|
15
|
+
|
|
16
|
+
## Designing for dark
|
|
17
|
+
|
|
18
|
+
- Never write a dark colour of your own or pick colours by theme in code.
|
|
19
|
+
- Surfaces get lighter as they rise: page darkest, cards one step lighter.
|
|
20
|
+
- The primary button turns light, and the solid status fills get brighter with dark text on them.
|
|
21
|
+
- Check every screen in both themes before release.
|
|
22
|
+
- Logos use their dark-background versions (see [Logos](/foundations/styles/logos/)).
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Color
|
|
3
|
+
description: Three brand colours and a set of colour tokens with one job each, for text, icons, surfaces, backgrounds, borders and status, in light and dark.
|
|
4
|
+
order: 1
|
|
5
|
+
sidebarLabel: Overview
|
|
6
|
+
---
|
|
7
|
+
import ColorDemo from '../../../../components/ColorDemo.astro';
|
|
8
|
+
|
|
9
|
+
Colour in Beehexa products is mostly graphite and white. Yellow marks the brand, and four functional colours mark status. You never pick a colour by its value: you pick a token by its job, such as `color.text` or `color.background.danger.bold`, and it is right in light and in dark.
|
|
10
|
+
|
|
11
|
+
<ColorDemo kind="balance" />
|
|
12
|
+
|
|
13
|
+
## Brand colours
|
|
14
|
+
|
|
15
|
+
<ColorDemo kind="brand" />
|
|
16
|
+
|
|
17
|
+
## Palette
|
|
18
|
+
|
|
19
|
+
Six scales of twelve steps, in light and dark. The brand graphite is graphite 12 in light; the brand yellow is yellow 7 in light and yellow 11 in dark. See every value in [Palette](/foundations/styles/color/palette/).
|
|
20
|
+
|
|
21
|
+
<ColorDemo kind="ramps" />
|
|
22
|
+
|
|
23
|
+
## How colour works
|
|
24
|
+
|
|
25
|
+
Colour comes in three tiers. You only ever use the middle one.
|
|
26
|
+
|
|
27
|
+
| Tier | Example | Who uses it |
|
|
28
|
+
|---|---|---|
|
|
29
|
+
| Palette | `color.graphite.11` | Nobody directly. It feeds the role tokens. |
|
|
30
|
+
| Role tokens | `color.text.subtle` | Every product and component. |
|
|
31
|
+
| Component tokens | `color.code.background` | Only where no role fits. |
|
|
32
|
+
|
|
33
|
+
Role tokens are listed in [Tokens](/foundations/styles/color/tokens/); how to pick one is in [Usage](/foundations/styles/color/usage/).
|
|
34
|
+
|
|
35
|
+
## Principles
|
|
36
|
+
|
|
37
|
+
### Graphite does the work, yellow is the accent
|
|
38
|
+
|
|
39
|
+
Text, icons, lines and the primary button are graphite. Yellow is only the logo, the current-page indicator, highlights and brand notes. It is never text and never a button: it is 1.85:1 on white.
|
|
40
|
+
|
|
41
|
+
<ColorDemo kind="dodont" item="yellow" />
|
|
42
|
+
|
|
43
|
+
### Colour means something
|
|
44
|
+
|
|
45
|
+
Red, orange, green and blue mean danger, warning, success and info. Don't use them to decorate or to draw attention.
|
|
46
|
+
|
|
47
|
+
<ColorDemo kind="dodont" item="meaning" />
|
|
48
|
+
|
|
49
|
+
### Never colour alone
|
|
50
|
+
|
|
51
|
+
Write the status in words and add an icon. Mark a selected item with a second cue besides colour. Colour blind people and screen reader users don't get the colour.
|
|
52
|
+
|
|
53
|
+
<ColorDemo kind="dodont" item="alone" />
|
|
54
|
+
|
|
55
|
+
### Use the token for the job
|
|
56
|
+
|
|
57
|
+
Use role tokens only. Never a hex value, and never a step of a scale such as `color.graphite.11`. If no token fits, ask for one.
|
|
58
|
+
|
|
59
|
+
<ColorDemo kind="dodont" item="tokens" />
|
|
60
|
+
|
|
61
|
+
### One primary button per view
|
|
62
|
+
|
|
63
|
+
The primary button is graphite. Every other button is a default button. There is no yellow button.
|
|
64
|
+
|
|
65
|
+
<ColorDemo kind="dodont" item="primary" />
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
---
|
|
2
|
+
title: Palette
|
|
3
|
+
description: Every colour in the system, as six scales of twelve steps in light and dark, what each scale and each step is for, and the contrast each step guarantees.
|
|
4
|
+
order: 3
|
|
5
|
+
---
|
|
6
|
+
import ColorDemo from '../../../../components/ColorDemo.astro';
|
|
7
|
+
|
|
8
|
+
**The palette feeds the role tokens. Products use the role tokens, never a palette step directly.**
|
|
9
|
+
|
|
10
|
+
Six scales of twelve steps. Hover a swatch to see its token name.
|
|
11
|
+
|
|
12
|
+
<ColorDemo kind="palette" />
|
|
13
|
+
|
|
14
|
+
## What each scale is for
|
|
15
|
+
|
|
16
|
+
| Scale | For | Never for |
|
|
17
|
+
|---|---|---|
|
|
18
|
+
| Graphite | Everything without a meaning: text, icons, lines, surfaces, the primary button | — |
|
|
19
|
+
| Yellow | The brand: logo, current-page indicator, highlights, brand notes | Text, buttons, warnings |
|
|
20
|
+
| Blue | Info, links, the focus ring | Decoration |
|
|
21
|
+
| Green | Success | Anything else |
|
|
22
|
+
| Orange | Warning | Anything else |
|
|
23
|
+
| Red | Danger | Anything else |
|
|
24
|
+
|
|
25
|
+
There is no purple, pink or teal. Charts have no palette yet: ask before colouring a chart.
|
|
26
|
+
|
|
27
|
+
## What each step is for
|
|
28
|
+
|
|
29
|
+
**Every step has one job, the same in every scale.**
|
|
30
|
+
|
|
31
|
+
<ColorDemo kind="steps" />
|
|
32
|
+
|
|
33
|
+
- **Steps 1–2:** page and surface backgrounds.
|
|
34
|
+
- **Steps 3–5:** component backgrounds at rest, on hover and when pressed or selected.
|
|
35
|
+
- **Steps 6–8:** borders and dividers, from subtle to strong.
|
|
36
|
+
- **Steps 9–10:** solid fills, such as a button, and their hover.
|
|
37
|
+
- **Steps 11–12:** text and icons. 11 is secondary, 12 is the default.
|
|
38
|
+
|
|
39
|
+
Graphite carries the neutral text, so its dark end has three text levels instead of two: 12 default, 11 secondary, 10 tertiary. Step 9 is the edge of a control and step 8 is disabled text.
|
|
40
|
+
|
|
41
|
+
Yellow is the one exception: its brand fill is step 7, the brand yellow, with graphite text on top. Products don't use yellow for other fills or for text.
|
|
42
|
+
|
|
43
|
+
## Light and dark
|
|
44
|
+
|
|
45
|
+
**Every step has a light and a dark value under the same name.**
|
|
46
|
+
|
|
47
|
+
`color.graphite.12` is the text colour in both themes. The role tokens switch on their own, so a screen never picks a dark colour by hand. In dark, the solid fills (steps 9 and 10) are lighter than in light, so the text on them is dark: use `text.on-bold`.
|
|
48
|
+
|
|
49
|
+
## Contrast you can count on
|
|
50
|
+
|
|
51
|
+
In both themes:
|
|
52
|
+
|
|
53
|
+
- In blue, green, orange and red, text on a solid fill (steps 9 and 10) reaches 4.5:1 with `text.on-bold`: white in light, dark in dark.
|
|
54
|
+
- Step 11 text reaches 4.5:1 on every background it is paired with.
|
|
55
|
+
- In graphite, steps 10, 11 and 12 all reach 4.5:1 as text; step 9 reaches 3:1 as the edge of a control.
|
|
56
|
+
|
|
57
|
+
See [Accessibility](/foundations/styles/color/accessibility/) for the pairs.
|