@xyd-js/components 0.1.0-xyd.0
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 +3 -0
- package/coder.ts +1 -0
- package/content.ts +3 -0
- package/dist/CTABanner-CWX9isVG.js +1 -0
- package/dist/CodeSample-C5YaEpAi.js +1 -0
- package/dist/HomeView-CnAj-VYl.js +1 -0
- package/dist/UnderlineNav-C8onw9Na.js +1 -0
- package/dist/_rollupPluginBabelHelpers-DfQAiTCw.js +1 -0
- package/dist/abap-kIO_7z1o.js +1 -0
- package/dist/actionscript-3-DiaraCXE.js +1 -0
- package/dist/ada-aNFKX2pl.js +1 -0
- package/dist/angular-html-y0qIEhS2.js +1 -0
- package/dist/angular-ts-Bn_6f37o.js +1 -0
- package/dist/apache-Cx7e0H64.js +1 -0
- package/dist/apex-CdSCJjuL.js +1 -0
- package/dist/apl-BDzWBUim.js +1 -0
- package/dist/applescript-CJFkzk5i.js +1 -0
- package/dist/ara-BC9R9M5c.js +1 -0
- package/dist/asciidoc-lqQQs4M0.js +1 -0
- package/dist/asm-QQeI-gwp.js +1 -0
- package/dist/astro-BPstp8LF.js +1 -0
- package/dist/awk-Cxb7Sqvk.js +1 -0
- package/dist/ballerina-G8TyVc6O.js +1 -0
- package/dist/bat-UDEmXz-g.js +1 -0
- package/dist/beancount-BWg86rhE.js +1 -0
- package/dist/berry-5E5uGOYg.js +1 -0
- package/dist/bibtex-CZn_FFnb.js +1 -0
- package/dist/bicep-D_G0XT5J.js +1 -0
- package/dist/blade-7dxmctkK.js +1 -0
- package/dist/brand.d.ts +30 -0
- package/dist/brand.js +1 -0
- package/dist/c-CrEz-oYf.js +1 -0
- package/dist/cadence-BulSIR1A.js +1 -0
- package/dist/clarity-m2OigCMT.js +1 -0
- package/dist/clojure-Bpes2rhL.js +1 -0
- package/dist/cmake-C4Tr1SQC.js +1 -0
- package/dist/cobol-Dp8xGW1S.js +1 -0
- package/dist/codeowners-Bs3mpoau.js +1 -0
- package/dist/codeql-CvQzaisq.js +1 -0
- package/dist/coder.d.ts +19 -0
- package/dist/coder.js +1 -0
- package/dist/coffee-DOjtyJj_.js +1 -0
- package/dist/common-lisp-DGVR8DFi.js +1 -0
- package/dist/content.d.ts +225 -0
- package/dist/content.js +1 -0
- package/dist/cpp-BUT7C4Bo.js +1 -0
- package/dist/crystal-BJh9OJ1_.js +1 -0
- package/dist/csharp-BhZuAD8H.js +1 -0
- package/dist/css-8_G4_UCW.js +1 -0
- package/dist/csv-DLRyYdMG.js +1 -0
- package/dist/cue-DAgMCCsT.js +1 -0
- package/dist/cypher-CtSiSKRh.js +1 -0
- package/dist/d-feZJOTtr.js +1 -0
- package/dist/dark-plus-Dcn2h2HL.js +1 -0
- package/dist/dart-CNOu4aud.js +1 -0
- package/dist/dax-Dkp1Uj6t.js +1 -0
- package/dist/desktop-CAGQzotA.js +1 -0
- package/dist/diff-D6yk3_ZG.js +1 -0
- package/dist/docker-BdTrQq0b.js +1 -0
- package/dist/dotenv-BeHGAMs7.js +1 -0
- package/dist/dracula-BUaMrXr0.js +1 -0
- package/dist/dracula-soft-CBx6n76m.js +1 -0
- package/dist/dream-maker-BU0sZZmb.js +1 -0
- package/dist/edge-D2Tk5tmg.js +1 -0
- package/dist/elixir-B-l3Nz-G.js +1 -0
- package/dist/elm-Bqm7aRpV.js +1 -0
- package/dist/emacs-lisp-BSvpfolf.js +1 -0
- package/dist/erb-CwBHxfFV.js +1 -0
- package/dist/erlang-B0PtHWg2.js +1 -0
- package/dist/fennel-CdN4E9Xo.js +1 -0
- package/dist/fish-XrbYjeRx.js +1 -0
- package/dist/fluent-zYsEgElv.js +1 -0
- package/dist/fortran-fixed-form-CPwX6okW.js +1 -0
- package/dist/fortran-free-form-B6Kk9658.js +1 -0
- package/dist/fsharp-CbMfVCMr.js +1 -0
- package/dist/gdresource-CdRUpBQO.js +1 -0
- package/dist/gdscript-CYXv_Ac9.js +1 -0
- package/dist/gdshader-CtiaGYI5.js +1 -0
- package/dist/genie-C-gOIth7.js +1 -0
- package/dist/gherkin-uGsOfG-k.js +1 -0
- package/dist/git-commit-CWQvkRNX.js +1 -0
- package/dist/git-rebase-BZ0YVJ-O.js +1 -0
- package/dist/github-dark-DCm4kydX.js +1 -0
- package/dist/github-dark-dimmed-CsRUrOJA.js +1 -0
- package/dist/github-from-css-CTRi6tFC.js +1 -0
- package/dist/github-light-B2ofRYMU.js +1 -0
- package/dist/gleam-C9ZZ3Vp2.js +1 -0
- package/dist/glimmer-js-Cuwfndkm.js +1 -0
- package/dist/glimmer-ts-D8nR8_k2.js +1 -0
- package/dist/glsl-qc_rLvzz.js +1 -0
- package/dist/gnuplot-BgHAcd--.js +1 -0
- package/dist/go-Dm8VBUM2.js +1 -0
- package/dist/graphql-CRmnB6D5.js +1 -0
- package/dist/groovy-DJcw8dX4.js +1 -0
- package/dist/hack-DYOVz52F.js +1 -0
- package/dist/haml-j8Vx_P4q.js +1 -0
- package/dist/handlebars-Qz3hgrPG.js +1 -0
- package/dist/haskell-DE3vVmXn.js +1 -0
- package/dist/haxe-DpuNPTTj.js +1 -0
- package/dist/hcl-BvV3VZ9s.js +1 -0
- package/dist/hjson-CsTZvU0B.js +1 -0
- package/dist/hlsl-BLZumTGu.js +1 -0
- package/dist/html-BJsWDmIe.js +1 -0
- package/dist/html-derivative-zDWJvwg5.js +1 -0
- package/dist/http-BiMppEBd.js +1 -0
- package/dist/hxml-DG2jWwyK.js +1 -0
- package/dist/hy-C9zVJlJf.js +1 -0
- package/dist/imba-DGD1mm8E.js +1 -0
- package/dist/index-TKJ66_wI.js +1 -0
- package/dist/index.css +135 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +1 -0
- package/dist/ini-CU7wgrgh.js +1 -0
- package/dist/java-DyOZhX5L.js +1 -0
- package/dist/javascript-C0AWZ4eK.js +1 -0
- package/dist/jinja-Lc82IfGI.js +1 -0
- package/dist/jison-DT7Oqeqm.js +1 -0
- package/dist/json-Zoq3rK60.js +1 -0
- package/dist/json5-BOFh3mt2.js +1 -0
- package/dist/jsonc-CPutX9W5.js +1 -0
- package/dist/jsonl-xWfKSBhV.js +1 -0
- package/dist/jsonnet-UcnvaLwK.js +1 -0
- package/dist/jssm-BRT8_Uqd.js +1 -0
- package/dist/jsx-B4WNxrCK.js +1 -0
- package/dist/julia-i7_3XSV_.js +1 -0
- package/dist/kotlin-B_s0KNy5.js +1 -0
- package/dist/kusto-CDr4m-xT.js +1 -0
- package/dist/latex-BNB6MZrj.js +1 -0
- package/dist/layouts.d.ts +19 -0
- package/dist/layouts.js +1 -0
- package/dist/lean-2dBp1asm.js +1 -0
- package/dist/less-CfPPFFsV.js +1 -0
- package/dist/light-plus-glPHycm5.js +1 -0
- package/dist/liquid-Bj1DN66U.js +1 -0
- package/dist/log-CKSz9t_o.js +1 -0
- package/dist/logo-D3UPVeLP.js +1 -0
- package/dist/lua-C1EFGxtA.js +1 -0
- package/dist/luau-Dvb2LLsw.js +1 -0
- package/dist/make-TqphZF-7.js +1 -0
- package/dist/markdown-yX62Igf3.js +1 -0
- package/dist/marko-LH6NoP97.js +1 -0
- package/dist/material-darker-D6whucX3.js +1 -0
- package/dist/material-default-DYqS7fqa.js +1 -0
- package/dist/material-from-css-DlWo_ZDV.js +1 -0
- package/dist/material-lighter-CYQaMsGh.js +1 -0
- package/dist/material-ocean-Dl_zLA-F.js +1 -0
- package/dist/material-palenight-Cd4X9kqy.js +1 -0
- package/dist/matlab-Dy9K5GW8.js +1 -0
- package/dist/mdc-DhAfBnnn.js +1 -0
- package/dist/mdx-tnT2uTqR.js +1 -0
- package/dist/mermaid-aEaCok9S.js +1 -0
- package/dist/min-dark-CpapYCVz.js +1 -0
- package/dist/min-light-plRN0zW-.js +1 -0
- package/dist/mojo-BanaVmFY.js +1 -0
- package/dist/monokai-Cs2_BG4b.js +1 -0
- package/dist/move-B_kaWhAV.js +1 -0
- package/dist/narrat-6tChrAmV.js +1 -0
- package/dist/nextflow-BYB6CU6V.js +1 -0
- package/dist/nginx-Clr7XfzW.js +1 -0
- package/dist/nim-gLesixmv.js +1 -0
- package/dist/nix-DCgUXh-o.js +1 -0
- package/dist/nord-BHSE8FbR.js +1 -0
- package/dist/nushell-DDKGkuZY.js +1 -0
- package/dist/objective-c-BsQdhSk0.js +1 -0
- package/dist/objective-cpp-B-VZlBXW.js +1 -0
- package/dist/ocaml-B19L2xxl.js +1 -0
- package/dist/one-dark-pro-AWPQgJbJ.js +1 -0
- package/dist/pages.d.ts +30 -0
- package/dist/pages.js +1 -0
- package/dist/pascal-B0kVBVTU.js +1 -0
- package/dist/perl-Bs2cXIO6.js +1 -0
- package/dist/php-BgaH_AHK.js +1 -0
- package/dist/plsql-CPY7hT9n.js +1 -0
- package/dist/po-BszTsnLZ.js +1 -0
- package/dist/poimandres-CZF4JUv5.js +1 -0
- package/dist/postcss-DQ0frX96.js +1 -0
- package/dist/powerquery-BitONm6p.js +1 -0
- package/dist/powershell-B_lVHVgu.js +1 -0
- package/dist/prisma-CqkE3olT.js +1 -0
- package/dist/prolog-Bpuon3aK.js +1 -0
- package/dist/proto-C349dup0.js +1 -0
- package/dist/pug-Bbf3g_hT.js +1 -0
- package/dist/puppet-qDtDc0so.js +1 -0
- package/dist/purescript-C03CHyrT.js +1 -0
- package/dist/python-D5e4BtVB.js +1 -0
- package/dist/qml-LVCeHqxw.js +1 -0
- package/dist/qmldir-BEg8Q-XX.js +1 -0
- package/dist/qss-vq-U9k0N.js +1 -0
- package/dist/r-DnCIdoUu.js +1 -0
- package/dist/racket-BQt8mf2o.js +1 -0
- package/dist/raku-ChTHpuBS.js +1 -0
- package/dist/razor-CjFZSXD2.js +1 -0
- package/dist/reg-12gGsscy.js +1 -0
- package/dist/regexp-zLCCZKTi.js +1 -0
- package/dist/rel-aZ4oe34Q.js +1 -0
- package/dist/riscv-BA9R8KI2.js +1 -0
- package/dist/rose-pine-8QECO0Ox.js +1 -0
- package/dist/rose-pine-dawn-DT77ObZh.js +1 -0
- package/dist/rose-pine-moon-D3-I8ETF.js +1 -0
- package/dist/rst-DFKlxnrd.js +1 -0
- package/dist/ruby-BypI_hk5.js +1 -0
- package/dist/rust-tE6tRkqD.js +1 -0
- package/dist/sas-D1sMUJql.js +1 -0
- package/dist/sass-DBEOLVv3.js +1 -0
- package/dist/scala-DUzir4os.js +1 -0
- package/dist/scheme-dsSqVZz3.js +1 -0
- package/dist/scss-B0kJw1gM.js +1 -0
- package/dist/shaderlab-Cd8Cbryn.js +1 -0
- package/dist/shellscript-BL-Ihj2z.js +1 -0
- package/dist/shellsession-C5KJPcFG.js +1 -0
- package/dist/slack-dark-JbsLGggd.js +1 -0
- package/dist/slack-ochin-hTeCADjA.js +1 -0
- package/dist/smalltalk-DQ23HuGh.js +1 -0
- package/dist/solarized-dark-D2bQRcX7.js +1 -0
- package/dist/solarized-light-6xrOKoxI.js +1 -0
- package/dist/solidity-DUCwohjn.js +1 -0
- package/dist/soy-Cy4pRjbu.js +1 -0
- package/dist/sparql-D7gNTkUq.js +1 -0
- package/dist/splunk-Dvl5Xm98.js +1 -0
- package/dist/sql-BfoT44Al.js +1 -0
- package/dist/ssh-config-C-ZFySPN.js +1 -0
- package/dist/stata-Dpw9jvge.js +1 -0
- package/dist/stylus-mJ9_5M6n.js +1 -0
- package/dist/svelte-DD5dtnEi.js +1 -0
- package/dist/swift-DDernUpH.js +1 -0
- package/dist/system-verilog-DeXSd9Py.js +1 -0
- package/dist/systemd-NetTuLPL.js +1 -0
- package/dist/tasl-BCm9L3tI.js +1 -0
- package/dist/tcl-DmWVgxCm.js +1 -0
- package/dist/templ-B7wt_K-d.js +1 -0
- package/dist/terraform-DYIIsq8p.js +1 -0
- package/dist/tex-DFj0qpOD.js +1 -0
- package/dist/toml-CFu3vY0Q.js +1 -0
- package/dist/ts-tags-BvMEeGTJ.js +1 -0
- package/dist/tslib.es6-C3PNVQlC.js +1 -0
- package/dist/tsv-DnenRF8k.js +1 -0
- package/dist/tsx-DooqfEr1.js +1 -0
- package/dist/turtle-DKlxyehf.js +1 -0
- package/dist/twig-DpQc8FUF.js +1 -0
- package/dist/txt-C4tHEtDr.js +1 -0
- package/dist/typescript-DtE5sB_4.js +1 -0
- package/dist/typespec-B69vp3jc.js +1 -0
- package/dist/typst-BzEngGMo.js +1 -0
- package/dist/v-Dy6tTX8K.js +1 -0
- package/dist/vala-DQnmDtkE.js +1 -0
- package/dist/vb-CqTjXY4K.js +1 -0
- package/dist/verilog-D6Zfe00a.js +1 -0
- package/dist/vhdl-Dxu0BOr9.js +1 -0
- package/dist/views.d.ts +17 -0
- package/dist/views.js +1 -0
- package/dist/viml-eXtfIM-m.js +1 -0
- package/dist/vue-D3vey6Cu.js +1 -0
- package/dist/vue-html-DyaqvCGV.js +1 -0
- package/dist/vyper-C6AULW8C.js +1 -0
- package/dist/wasm-Cl39COlm.js +1 -0
- package/dist/wenyan-DJGdsiXE.js +1 -0
- package/dist/wgsl-CDhIPMwJ.js +1 -0
- package/dist/wikitext-D05PpJ8X.js +1 -0
- package/dist/wolfram-JgWnd2g7.js +1 -0
- package/dist/writer.d.ts +157 -0
- package/dist/writer.js +1 -0
- package/dist/xml-Cc1Sy-d4.js +1 -0
- package/dist/xsl-CEYTrbD0.js +1 -0
- package/dist/yaml-NvTdC05o.js +1 -0
- package/dist/zenscript-De0mU_BW.js +1 -0
- package/dist/zig-D9TJVGyp.js +1 -0
- package/index.ts +1 -0
- package/layouts.ts +1 -0
- package/package.json +58 -0
- package/postcss.config.cjs +5 -0
- package/rollup.config.js +149 -0
- package/src/brand/Button/Button.tsx +48 -0
- package/src/brand/Button/index.ts +7 -0
- package/src/brand/CTABanner/CTABanner.tsx +127 -0
- package/src/brand/CTABanner/index.ts +8 -0
- package/src/brand/Footer/Footer.tsx +36 -0
- package/src/brand/Footer/index.ts +3 -0
- package/src/brand/index.ts +5 -0
- package/src/coder/CodeCopy/CodeCopy.style.tsx +21 -0
- package/src/coder/CodeCopy/CodeCopy.tsx +32 -0
- package/src/coder/CodeCopy/index.ts +7 -0
- package/src/coder/CodeSample/CodeSample.styles.tsx +137 -0
- package/src/coder/CodeSample/CodeSample.tsx +150 -0
- package/src/coder/CodeSample/default-theme.ts +266 -0
- package/src/coder/CodeSample/index.ts +12 -0
- package/src/coder/CodeSample/withLocalStored.tsx +50 -0
- package/src/coder/README.md +1 -0
- package/src/coder/index.ts +3 -0
- package/src/content/Anchor/Anchor.tsx +63 -0
- package/src/content/Anchor/index.tsx +3 -0
- package/src/content/Content/Content.tsx +20 -0
- package/src/content/Content/index.tsx +3 -0
- package/src/content/Content.tsx +137 -0
- package/src/content/Subtitle/Subtitle.tsx +21 -0
- package/src/content/Subtitle/index.tsx +3 -0
- package/src/content/index.ts +3 -0
- package/src/layouts/Layout.styles.tsx +151 -0
- package/src/layouts/Layout.tsx +121 -0
- package/src/layouts/index.ts +7 -0
- package/src/pages/HomePage/HomePage.tsx +93 -0
- package/src/pages/HomePage/index.ts +5 -0
- package/src/pages/HomePage/types.ts +41 -0
- package/src/pages/index.ts +1 -0
- package/src/views/HomeView/HomeView.tsx +74 -0
- package/src/views/HomeView/index.ts +3 -0
- package/src/views/index.ts +1 -0
- package/src/writer/Badge/Badge.styles.tsx +29 -0
- package/src/writer/Badge/Badge.tsx +28 -0
- package/src/writer/Badge/index.ts +7 -0
- package/src/writer/Blockquote/Blockquote.styles.tsx +10 -0
- package/src/writer/Blockquote/Blockquote.tsx +13 -0
- package/src/writer/Blockquote/index.ts +7 -0
- package/src/writer/Breadcrumbs/Breadcrumbs.styles.ts +28 -0
- package/src/writer/Breadcrumbs/Breadcrumbs.tsx +46 -0
- package/src/writer/Breadcrumbs/index.ts +7 -0
- package/src/writer/Callout/Callout.styles.tsx +50 -0
- package/src/writer/Callout/Callout.tsx +37 -0
- package/src/writer/Callout/index.tsx +3 -0
- package/src/writer/Code/Code.styles.tsx +17 -0
- package/src/writer/Code/Code.tsx +13 -0
- package/src/writer/Code/index.ts +3 -0
- package/src/writer/Details/Details.styles.tsx +76 -0
- package/src/writer/Details/Details.tsx +122 -0
- package/src/writer/Details/index.ts +3 -0
- package/src/writer/GuideCard/GuideCard.styles.tsx +115 -0
- package/src/writer/GuideCard/GuideCard.tsx +81 -0
- package/src/writer/GuideCard/index.ts +1 -0
- package/src/writer/Heading/Heading.styles.tsx +73 -0
- package/src/writer/Heading/Heading.tsx +53 -0
- package/src/writer/Heading/index.ts +7 -0
- package/src/writer/Hr/Hr.styles.tsx +7 -0
- package/src/writer/Hr/Hr.tsx +13 -0
- package/src/writer/Hr/index.ts +3 -0
- package/src/writer/Icon/index.tsx +112 -0
- package/src/writer/NavLinks/NavLinks.styles.ts +32 -0
- package/src/writer/NavLinks/NavLinks.tsx +48 -0
- package/src/writer/NavLinks/index.ts +7 -0
- package/src/writer/Pre/Pre.styles.tsx +13 -0
- package/src/writer/Pre/Pre.tsx +13 -0
- package/src/writer/Pre/index.ts +3 -0
- package/src/writer/README.md +1 -0
- package/src/writer/Steps/Steps.styles.tsx +36 -0
- package/src/writer/Steps/Steps.tsx +24 -0
- package/src/writer/Steps/index.ts +5 -0
- package/src/writer/Table/Table.styles.tsx +39 -0
- package/src/writer/Table/Table.tsx +45 -0
- package/src/writer/Table/index.ts +10 -0
- package/src/writer/Tabs/Tabs.styles.tsx +77 -0
- package/src/writer/Tabs/Tabs.tsx +104 -0
- package/src/writer/Tabs/index.ts +7 -0
- package/src/writer/UnderlineNav/UnderlineNav.styles.tsx +45 -0
- package/src/writer/UnderlineNav/UnderlineNav.tsx +38 -0
- package/src/writer/UnderlineNav/index.ts +1 -0
- package/src/writer/index.ts +32 -0
- package/tsconfig.json +41 -0
- package/writer.ts +1 -0
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
|
|
3
|
+
export interface IHomePageHero {
|
|
4
|
+
// The main text for the hero section. This will be defined
|
|
5
|
+
// as `h1` tag.
|
|
6
|
+
text: string
|
|
7
|
+
|
|
8
|
+
// Whether to apply text effect on `text`. Defaults to `false`.
|
|
9
|
+
textEffect?: boolean
|
|
10
|
+
|
|
11
|
+
// Subtitle displayed below `text`.
|
|
12
|
+
subtitle?: string | React.ReactNode
|
|
13
|
+
|
|
14
|
+
// Action buttons to display in home hero section.
|
|
15
|
+
actions?: IHomePageHeroAction[]
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export interface IHomePageHeroAction {
|
|
19
|
+
// Label of the button.
|
|
20
|
+
text: string
|
|
21
|
+
|
|
22
|
+
// Color theme of the button. Defaults to `brand`.
|
|
23
|
+
kind?: 'secondary'
|
|
24
|
+
|
|
25
|
+
// Link href attribute.
|
|
26
|
+
href?: string
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
export interface IHomePageFeature {
|
|
30
|
+
// Title of the feature.
|
|
31
|
+
title: string
|
|
32
|
+
|
|
33
|
+
// Details of the feature.
|
|
34
|
+
description: string | React.ReactNode
|
|
35
|
+
|
|
36
|
+
// Show icon on each feature box.
|
|
37
|
+
icon?: React.ReactNode
|
|
38
|
+
|
|
39
|
+
// Link href attribute
|
|
40
|
+
href?: string
|
|
41
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./HomePage"
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
import {css} from "@linaria/core";
|
|
3
|
+
|
|
4
|
+
const $homeView = {
|
|
5
|
+
host: css`
|
|
6
|
+
display: flex;
|
|
7
|
+
flex-direction: column;
|
|
8
|
+
min-height: 100vh;
|
|
9
|
+
`,
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export interface HomeViewProps {
|
|
13
|
+
header: React.ReactNode
|
|
14
|
+
body: React.ReactNode
|
|
15
|
+
footer: React.ReactNode
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export function HomeView({header, body, footer}: HomeViewProps) {
|
|
19
|
+
return <div className={$homeView.host}>
|
|
20
|
+
{header}
|
|
21
|
+
{body}
|
|
22
|
+
{footer}
|
|
23
|
+
</div>
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
const $body = {
|
|
27
|
+
host: css`
|
|
28
|
+
background: radial-gradient(circle, hsl(0 0% 9% / .3) 1px, transparent 1px);
|
|
29
|
+
backdrop-filter: sepia(10%);
|
|
30
|
+
background-size: 30px 30px;
|
|
31
|
+
padding: 60px;
|
|
32
|
+
flex: 1;
|
|
33
|
+
`,
|
|
34
|
+
host$$secondary: css`
|
|
35
|
+
background: repeating-linear-gradient(to right, hsl(0 0% 9% / .1), hsl(0 0% 9% / .1) 1px, transparent 1px, transparent 50px), repeating-linear-gradient(to bottom, hsl(0 0% 9% / .1), hsl(0 0% 9% / .1) 1px, transparent 1px, transparent 50px);
|
|
36
|
+
`,
|
|
37
|
+
body: css`
|
|
38
|
+
width: 1200px;
|
|
39
|
+
margin: 0 auto;
|
|
40
|
+
display: flex;
|
|
41
|
+
flex-direction: column;
|
|
42
|
+
gap: 80px;
|
|
43
|
+
|
|
44
|
+
@media (max-width: 1200px) {
|
|
45
|
+
width: 100%;
|
|
46
|
+
padding: 0 20px;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
@media (max-width: 768px) {
|
|
50
|
+
width: 100%;
|
|
51
|
+
padding: 0 10px;
|
|
52
|
+
}
|
|
53
|
+
`
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export interface HomeViewBodyProps {
|
|
57
|
+
children: React.ReactNode
|
|
58
|
+
kind?: "secondary"
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
HomeView.Body = function HomeViewBody({children, kind}: HomeViewBodyProps) {
|
|
62
|
+
return <div className={`
|
|
63
|
+
${$body.host}
|
|
64
|
+
${kind === "secondary" ? $body.host$$secondary : ""}
|
|
65
|
+
`}>
|
|
66
|
+
<div className={`
|
|
67
|
+
${$body.body}
|
|
68
|
+
`}>
|
|
69
|
+
{children}
|
|
70
|
+
</div>
|
|
71
|
+
</div>
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from "./HomeView";
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import {css} from "@linaria/core";
|
|
2
|
+
|
|
3
|
+
export const $badge = {
|
|
4
|
+
host: css`
|
|
5
|
+
display: inline-flex;
|
|
6
|
+
align-items: center;
|
|
7
|
+
line-height: 1rem;
|
|
8
|
+
font-style: normal;
|
|
9
|
+
font-weight: 500;
|
|
10
|
+
letter-spacing: normal;
|
|
11
|
+
white-space: nowrap;
|
|
12
|
+
text-transform: none;
|
|
13
|
+
`,
|
|
14
|
+
host$$warning: css`
|
|
15
|
+
color: #000;
|
|
16
|
+
background-color: #f8d047;
|
|
17
|
+
`,
|
|
18
|
+
host$$sm: css`
|
|
19
|
+
font-size: 12px;
|
|
20
|
+
height: 18px;
|
|
21
|
+
padding: 0 6px;
|
|
22
|
+
gap: 3px;
|
|
23
|
+
border-radius: 6px;
|
|
24
|
+
`,
|
|
25
|
+
|
|
26
|
+
item: css`
|
|
27
|
+
position: relative;
|
|
28
|
+
`
|
|
29
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
|
|
3
|
+
import {$badge} from "./Badge.styles";
|
|
4
|
+
|
|
5
|
+
export interface BadgeProps {
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
|
|
8
|
+
size?: "sm"
|
|
9
|
+
kind?: "warning"
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export function Badge({
|
|
13
|
+
children,
|
|
14
|
+
size = "sm",
|
|
15
|
+
kind = "warning"
|
|
16
|
+
}: BadgeProps) {
|
|
17
|
+
return <div className={`
|
|
18
|
+
${$badge.host}
|
|
19
|
+
|
|
20
|
+
${size === "sm" && $badge.host$$sm}
|
|
21
|
+
|
|
22
|
+
${kind === "warning" && $badge.host$$warning}
|
|
23
|
+
`}>
|
|
24
|
+
<span className={$badge.item}>
|
|
25
|
+
{children}
|
|
26
|
+
</span>
|
|
27
|
+
</div>
|
|
28
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
|
|
3
|
+
import {$blockquote} from "./Blockquote.styles";
|
|
4
|
+
|
|
5
|
+
export interface BlockquoteProps {
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
export function Blockquote({children}: BlockquoteProps) {
|
|
10
|
+
return <blockquote className={$blockquote.host}>
|
|
11
|
+
{children}
|
|
12
|
+
</blockquote>
|
|
13
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import {css} from "@linaria/core";
|
|
2
|
+
|
|
3
|
+
export const $breadcrumbs = {
|
|
4
|
+
host: css`
|
|
5
|
+
display: flex;
|
|
6
|
+
overflow: hidden;
|
|
7
|
+
margin-top: 0.375rem;
|
|
8
|
+
gap: 0.25rem;
|
|
9
|
+
align-items: center;
|
|
10
|
+
font-size: 0.875rem;
|
|
11
|
+
line-height: 1.25rem;
|
|
12
|
+
color: #6B7280;
|
|
13
|
+
`,
|
|
14
|
+
icon: css`
|
|
15
|
+
shrink: 0;
|
|
16
|
+
width: 0.875rem;
|
|
17
|
+
`,
|
|
18
|
+
item: css`
|
|
19
|
+
white-space: nowrap;
|
|
20
|
+
transition-property: color, background-color, border-color, text-decoration-color, fill, stroke;
|
|
21
|
+
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
|
22
|
+
transition-duration: 300ms;
|
|
23
|
+
`,
|
|
24
|
+
item$$active: css`
|
|
25
|
+
color: #000;
|
|
26
|
+
font-weight: bold;
|
|
27
|
+
`
|
|
28
|
+
};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import React, {Fragment} from 'react'
|
|
2
|
+
import type {ReactElement} from 'react'
|
|
3
|
+
import {ArrowRightIcon} from '@radix-ui/react-icons'
|
|
4
|
+
|
|
5
|
+
import {$breadcrumbs} from './Breadcrumbs.styles'
|
|
6
|
+
|
|
7
|
+
function Anchor({children, ...rest}) {
|
|
8
|
+
return <a {...rest}>
|
|
9
|
+
{children}
|
|
10
|
+
</a>
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
export interface BreadcrumbsProps {
|
|
14
|
+
items: {
|
|
15
|
+
title: string
|
|
16
|
+
href?: string
|
|
17
|
+
}[]
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
export function Breadcrumbs(props: BreadcrumbsProps): ReactElement {
|
|
21
|
+
return (
|
|
22
|
+
<div className={$breadcrumbs.host}>
|
|
23
|
+
{props.items.map((item, index) => {
|
|
24
|
+
const lastActive = index === props.items.length - 1
|
|
25
|
+
|
|
26
|
+
return (
|
|
27
|
+
<Fragment key={item.href + item.title}>
|
|
28
|
+
{index > 0 && <ArrowRightIcon className={$breadcrumbs.icon}/>}
|
|
29
|
+
<div className={`
|
|
30
|
+
${$breadcrumbs.item}
|
|
31
|
+
${lastActive && $breadcrumbs.item$$active}
|
|
32
|
+
`}
|
|
33
|
+
title={item.title}
|
|
34
|
+
>
|
|
35
|
+
{item.href && !lastActive ? (
|
|
36
|
+
<Anchor href={item.href}>{item.title}</Anchor>
|
|
37
|
+
) : (
|
|
38
|
+
item.title
|
|
39
|
+
)}
|
|
40
|
+
</div>
|
|
41
|
+
</Fragment>
|
|
42
|
+
)
|
|
43
|
+
})}
|
|
44
|
+
</div>
|
|
45
|
+
)
|
|
46
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
import {css} from "@linaria/core";
|
|
2
|
+
|
|
3
|
+
export const $callout = {
|
|
4
|
+
host: css`
|
|
5
|
+
display: inline-flex;
|
|
6
|
+
align-items: center;
|
|
7
|
+
|
|
8
|
+
position: relative;
|
|
9
|
+
width: 100%;
|
|
10
|
+
min-width: 275px;
|
|
11
|
+
padding: 8px 12px;
|
|
12
|
+
|
|
13
|
+
border-radius: 8px;
|
|
14
|
+
|
|
15
|
+
text-align: center;
|
|
16
|
+
|
|
17
|
+
border: 1px solid #ececf1;
|
|
18
|
+
`,
|
|
19
|
+
$$neutral: css`
|
|
20
|
+
background-color: #f7f7f8;
|
|
21
|
+
|
|
22
|
+
border-color: #ececf1;
|
|
23
|
+
`
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export const $icon = {
|
|
27
|
+
host: css`
|
|
28
|
+
display: inline-flex;
|
|
29
|
+
margin-right: 14px;
|
|
30
|
+
flex: 0 0 auto;
|
|
31
|
+
align-self: flex-start;
|
|
32
|
+
|
|
33
|
+
color: #6e6e80;
|
|
34
|
+
font-size: 20px;
|
|
35
|
+
margin-top: 2px;
|
|
36
|
+
`
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export const $message = {
|
|
40
|
+
host: css`
|
|
41
|
+
color: #353740;
|
|
42
|
+
text-align: left;
|
|
43
|
+
|
|
44
|
+
flex: 1 1 auto;
|
|
45
|
+
`,
|
|
46
|
+
body: css`
|
|
47
|
+
font-size: 14px;
|
|
48
|
+
line-height: 20px;
|
|
49
|
+
`
|
|
50
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
|
|
3
|
+
import {$callout, $icon, $message} from "./Callout.styles";
|
|
4
|
+
|
|
5
|
+
export interface CalloutProps {
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
function InfoIcon() {
|
|
10
|
+
return <svg
|
|
11
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
12
|
+
width="1em"
|
|
13
|
+
height="1em"
|
|
14
|
+
fill="currentColor"
|
|
15
|
+
viewBox="0 0 24 24"
|
|
16
|
+
>
|
|
17
|
+
<path d="M13 12a1 1 0 1 0-2 0v4a1 1 0 1 0 2 0v-4Zm-1-2.5A1.25 1.25 0 1 0 12 7a1.25 1.25 0 0 0 0 2.5Z"/>
|
|
18
|
+
<path
|
|
19
|
+
fillRule="evenodd"
|
|
20
|
+
d="M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2ZM4 12a8 8 0 1 1 16 0 8 8 0 0 1-16 0Z"
|
|
21
|
+
clipRule="evenodd"
|
|
22
|
+
/>
|
|
23
|
+
</svg>
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
export function Callout({children}: CalloutProps) {
|
|
27
|
+
return <div className={`${$callout.host} ${$callout.$$neutral}`}>
|
|
28
|
+
<div className={$icon.host}>
|
|
29
|
+
<InfoIcon/>
|
|
30
|
+
</div>
|
|
31
|
+
<div className={$message.host}>
|
|
32
|
+
<div className={$message.body}>
|
|
33
|
+
{children}
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import {css} from "@linaria/core";
|
|
2
|
+
|
|
3
|
+
export const $code = {
|
|
4
|
+
host: css`
|
|
5
|
+
display: inline-block;
|
|
6
|
+
padding: 0 .3em;
|
|
7
|
+
border-radius: 6px;
|
|
8
|
+
margin: 0 3px;
|
|
9
|
+
border: .5px solid #ececf1;
|
|
10
|
+
|
|
11
|
+
font-size: 14px;
|
|
12
|
+
font-weight: 500;
|
|
13
|
+
line-height: 1.6em;
|
|
14
|
+
|
|
15
|
+
background: linear-gradient(45deg, #f7f7f8 0%, rgba(247, 247, 248, 1) 100%);
|
|
16
|
+
`
|
|
17
|
+
}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import {css} from "@linaria/core";
|
|
2
|
+
|
|
3
|
+
export const $details = {
|
|
4
|
+
host: css`
|
|
5
|
+
border-top: 1px solid #ececf1;
|
|
6
|
+
|
|
7
|
+
&[open] summary svg[data-icon="true"] { // TODO: bad solution
|
|
8
|
+
transform: rotate(90deg);
|
|
9
|
+
}
|
|
10
|
+
`,
|
|
11
|
+
host$$secondary: css`
|
|
12
|
+
background-color: #f7f7f8;
|
|
13
|
+
border: 1px solid #ececf1;
|
|
14
|
+
border-radius: 8px;
|
|
15
|
+
`,
|
|
16
|
+
summary: css`
|
|
17
|
+
padding: 16px 14px 16px 0;
|
|
18
|
+
font-size: 18px;
|
|
19
|
+
cursor: pointer;
|
|
20
|
+
font-weight: 500;
|
|
21
|
+
font-variant-numeric: tabular-nums;
|
|
22
|
+
line-height: 1.4;
|
|
23
|
+
transition: color 0.3s;
|
|
24
|
+
display: flex;
|
|
25
|
+
flex-direction: row;
|
|
26
|
+
align-items: center;
|
|
27
|
+
justify-content: flex-start;
|
|
28
|
+
list-style: none;
|
|
29
|
+
|
|
30
|
+
&:hover {
|
|
31
|
+
color: #565869;
|
|
32
|
+
}
|
|
33
|
+
`,
|
|
34
|
+
summary$$secondary: css`
|
|
35
|
+
display: flex;
|
|
36
|
+
justify-content: space-between;
|
|
37
|
+
align-items: center;
|
|
38
|
+
cursor: pointer;
|
|
39
|
+
padding: 20px 24px;
|
|
40
|
+
`,
|
|
41
|
+
summaryDeep: css`
|
|
42
|
+
display: flex;
|
|
43
|
+
align-items: center;
|
|
44
|
+
margin-bottom: 8px;
|
|
45
|
+
`,
|
|
46
|
+
summaryDeep$text: css`
|
|
47
|
+
color: #6e6e80;
|
|
48
|
+
text-transform: uppercase;
|
|
49
|
+
font-size: 12px;
|
|
50
|
+
line-height: 16px;
|
|
51
|
+
letter-spacing: .08em;
|
|
52
|
+
margin-left: 8px;
|
|
53
|
+
font-weight: 700;
|
|
54
|
+
`,
|
|
55
|
+
label: css`
|
|
56
|
+
flex: 1 1 auto;
|
|
57
|
+
`,
|
|
58
|
+
icon: css`
|
|
59
|
+
flex: 0 0 auto;
|
|
60
|
+
font-size: 16px;
|
|
61
|
+
display: flex;
|
|
62
|
+
align-items: center;
|
|
63
|
+
justify-content: center;
|
|
64
|
+
padding-right: 6px;
|
|
65
|
+
`,
|
|
66
|
+
content: css`
|
|
67
|
+
padding: 0 24px 20px;
|
|
68
|
+
`,
|
|
69
|
+
content$$secondary: css`
|
|
70
|
+
// TODO: also bad
|
|
71
|
+
|
|
72
|
+
code {
|
|
73
|
+
background: white;
|
|
74
|
+
}
|
|
75
|
+
`
|
|
76
|
+
}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
import React from "react"
|
|
2
|
+
|
|
3
|
+
import {$details} from "./Details.styles";
|
|
4
|
+
|
|
5
|
+
interface BaseDetailsProps {
|
|
6
|
+
children: React.ReactNode;
|
|
7
|
+
label: string;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
interface SecondaryDetailsProps extends BaseDetailsProps {
|
|
11
|
+
kind: "secondary";
|
|
12
|
+
title: string;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
interface PrimaryDetailsProps extends BaseDetailsProps {
|
|
16
|
+
kind?: "primary";
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
export type DetailsProps = PrimaryDetailsProps | SecondaryDetailsProps;
|
|
20
|
+
|
|
21
|
+
export function Details(props: DetailsProps) {
|
|
22
|
+
let title = "";
|
|
23
|
+
const {children, label} = props;
|
|
24
|
+
|
|
25
|
+
if (props.kind === "secondary") {
|
|
26
|
+
title = props.title;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
const kind = props.kind || "primary";
|
|
30
|
+
|
|
31
|
+
return <details className={`
|
|
32
|
+
${$details.host}
|
|
33
|
+
${kind === "secondary" && $details.host$$secondary}
|
|
34
|
+
`}>
|
|
35
|
+
<summary className={`
|
|
36
|
+
${$details.summary}
|
|
37
|
+
${kind === "secondary" && $details.summary$$secondary}
|
|
38
|
+
`}>
|
|
39
|
+
{kind === "primary" && <>
|
|
40
|
+
<$Icon/>
|
|
41
|
+
<$Label>
|
|
42
|
+
{label}
|
|
43
|
+
</$Label>
|
|
44
|
+
</>}
|
|
45
|
+
{kind === "secondary" && <>
|
|
46
|
+
<div>
|
|
47
|
+
<div className={$details.summaryDeep}>
|
|
48
|
+
<$IconDeep/>
|
|
49
|
+
<div className={$details.summaryDeep$text}>
|
|
50
|
+
{title}
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
<$Label>
|
|
54
|
+
{label}
|
|
55
|
+
</$Label>
|
|
56
|
+
</div>
|
|
57
|
+
<$Icon/>
|
|
58
|
+
</>}
|
|
59
|
+
</summary>
|
|
60
|
+
|
|
61
|
+
<div className={`
|
|
62
|
+
${$details.content}
|
|
63
|
+
${kind === "secondary" && $details.content$$secondary}
|
|
64
|
+
`}>
|
|
65
|
+
{children}
|
|
66
|
+
</div>
|
|
67
|
+
</details>
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
function $Icon() {
|
|
71
|
+
return <div className={$details.icon}>
|
|
72
|
+
<svg
|
|
73
|
+
// TODO: bad solution
|
|
74
|
+
data-icon="true"
|
|
75
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
76
|
+
width="1em"
|
|
77
|
+
height="1em"
|
|
78
|
+
fill="currentColor"
|
|
79
|
+
viewBox="0 0 24 24"
|
|
80
|
+
>
|
|
81
|
+
<path
|
|
82
|
+
fillRule="evenodd"
|
|
83
|
+
d="M8.293 4.293a1 1 0 0 1 1.414 0l7 7a1 1 0 0 1 0 1.414l-7 7a1 1 0 0 1-1.414-1.414L14.586 12 8.293 5.707a1 1 0 0 1 0-1.414Z"
|
|
84
|
+
clipRule="evenodd"
|
|
85
|
+
/>
|
|
86
|
+
</svg>
|
|
87
|
+
</div>
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
function $IconDeep() {
|
|
91
|
+
return <svg
|
|
92
|
+
width="1em"
|
|
93
|
+
height="1em"
|
|
94
|
+
viewBox="0 0 24 24"
|
|
95
|
+
stroke="none"
|
|
96
|
+
fill="none"
|
|
97
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
98
|
+
>
|
|
99
|
+
<g clipPath="url(#clip0_1689_2180)">
|
|
100
|
+
<path
|
|
101
|
+
d="M4.3 4.3L7.1 7.1M10.6 5.7V1.5M14.8 7.8L17.6 5M5.7 11.3H1.5M7.1 14.8L4.3 17.6M15.5 22.5L9.9 9.9L22.5 14.8L16.9 16.2L15.5 22.5Z"
|
|
102
|
+
stroke="black"
|
|
103
|
+
strokeWidth={2}
|
|
104
|
+
strokeLinecap="round"
|
|
105
|
+
strokeLinejoin="round"
|
|
106
|
+
/>
|
|
107
|
+
</g>
|
|
108
|
+
<defs>
|
|
109
|
+
<clipPath id="clip0_1689_2180">
|
|
110
|
+
<rect width={24} height={24} fill="white"/>
|
|
111
|
+
</clipPath>
|
|
112
|
+
</defs>
|
|
113
|
+
</svg>
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
function $Label({children}: {
|
|
117
|
+
children?: React.ReactNode
|
|
118
|
+
}) {
|
|
119
|
+
return <div className={$details.label}>
|
|
120
|
+
{children}
|
|
121
|
+
</div>
|
|
122
|
+
}
|