@stackshift-ui/blockstyle 6.0.11 → 6.1.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/dist/blockstyle.js +1 -1
- package/dist/blockstyle.mjs +1 -1
- package/dist/chunk-34BAENR7.mjs +1 -0
- package/dist/chunk-MWQ5ZP4S.mjs +1 -0
- package/dist/defaultBlockStyle.js +1 -1
- package/dist/defaultBlockStyle.mjs +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +1 -1
- package/package.json +10 -10
- package/src/blockstyle.test.tsx +1 -1
- package/src/blockstyle.tsx +2 -2
- package/src/defaultBlockStyle.tsx +16 -6
- package/dist/chunk-GLR2G3MJ.mjs +0 -1
- package/dist/chunk-INK7XA5Q.mjs +0 -1
package/dist/blockstyle.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var r=Object.defineProperty;var y=Object.getOwnPropertyDescriptor;var k=Object.getOwnPropertyNames;var N=Object.prototype.hasOwnProperty;var w=(e,l)=>{for(var o in l)r(e,o,{get:l[o],enumerable:!0})},T=(e,l,o,a)=>{if(l&&typeof l=="object"||typeof l=="function")for(let m of k(l))!N.call(e,m)&&m!==o&&r(e,m,{get:()=>l[m],enumerable:!(a=y(l,m))||a.enumerable});return e};var S=e=>T(r({},"__esModule",{value:!0}),e);var H={};w(H,{Blockstyle:()=>f});module.exports=S(H);var x=require("@portabletext/react"),s=require("@stackshift-ui/system");var n=require("@stackshift-ui/heading"),c=require("@stackshift-ui/image"),d=require("@stackshift-ui/link"),p=require("@stackshift-ui/text"),t=require("react/jsx-runtime"),g={block:{h1:({children:e})=>(0,t.jsx)(n.Heading,{fontSize:"5xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h2:({children:e})=>(0,t.jsx)(n.Heading,{type:"h2",weight:"bold",fontSize:"4xl",className:"mb-8 text-black",children:e}),h3:({children:e})=>(0,t.jsx)(n.Heading,{type:"h3",fontSize:"3xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h4:({children:e})=>(0,t.jsx)(n.Heading,{type:"h4",weight:"bold",fontSize:"2xl",className:"mb-8 leading-normal text-black",children:e}),h5:({children:e})=>(0,t.jsx)(n.Heading,{type:"h4",weight:"bold",fontSize:"xl",className:"mb-8 leading-normal text-black",children:e}),h6:({children:e})=>(0,t.jsx)(n.Heading,{type:"h4",weight:"bold",fontSize:"lg",className:"mb-8 leading-normal text-black",children:e}),normal:({children:e})=>(0,t.jsx)(p.Text,{className:"mb-8 leading-relaxed",children:e}),blockquote:({children:e})=>(0,t.jsxs)("blockquote",{className:"mb-6 italic leading-loose text-gray-500 px-14",children:["- ",e]})},code:({value:e})=>(0,t.jsx)("pre",{"data-language":e.language,children:(0,t.jsx)("code",{children:e.code})}),list:{bullet:({children:e})=>(0,t.jsx)("ul",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-disc",children:e}),number:({children:e})=>(0,t.jsx)("ol",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-decimal",children:e})},listItem:{bullet:({children:e})=>(0,t.jsx)("li",{className:"leading-relaxed",children:e}),number:({children:e})=>(0,t.jsx)("li",{className:"leading-relaxed",children:e})},marks:{strong:({children:e})=>(0,t.jsx)("strong",{children:e}),em:({children:e})=>(0,t.jsx)("em",{children:e}),code:({children:e})=>(0,t.jsx)("code",{children:e}),link:({children:e,value:l})=>(0,t.jsx)(d.Link,{className:"hover:text-primary-foreground text-primary",href:l.href,target:"_blank",rel:"noopener noreferrer",children:e})},types:{addImage:({value:e})=>{var l,o,a;return(0,t.jsx)(c.Image,{className:"w-full h-full mb-5",width:500,height:500,sizes:"(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 33vw",src:e==null?void 0:e.image,alt:(a=e==null?void 0:e.alt)!=null?a:(o=(l=e==null?void 0:e.image)==null?void 0:l.asset)==null?void 0:o._ref})}}};var b="Blockstyle",f=({children:e,className:l,as:o,content:a,...m})=>{let{[b]:h=s.DefaultComponent}=(0,s.useStackShiftUIComponents)();return(0,t.jsx)(h,{as:o,className:l,...m,children:a?(0,t.jsx)(x.PortableText,{value:a,components:g}):e})};f.displayName=b;0&&(module.exports={Blockstyle});
|
package/dist/blockstyle.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
1
|
+
import{a}from"./chunk-34BAENR7.mjs";import"./chunk-MWQ5ZP4S.mjs";export{a as Blockstyle};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as t}from"./chunk-MWQ5ZP4S.mjs";import{PortableText as r}from"@portabletext/react";import{DefaultComponent as c,useStackShiftUIComponents as y}from"@stackshift-ui/system";import{jsx as o}from"react/jsx-runtime";var s="Blockstyle",i=({children:l,className:a,as:n,content:e,...m})=>{let{[s]:p=c}=y();return o(p,{as:n,className:a,...m,children:e?o(r,{value:e,components:t}):l})};i.displayName=s;export{i as a};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{Heading as t}from"@stackshift-ui/heading";import{Image as i}from"@stackshift-ui/image";import{Link as n}from"@stackshift-ui/link";import{Text as r}from"@stackshift-ui/text";import{jsx as l,jsxs as s}from"react/jsx-runtime";var x={block:{h1:({children:e})=>l(t,{fontSize:"5xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h2:({children:e})=>l(t,{type:"h2",weight:"bold",fontSize:"4xl",className:"mb-8 text-black",children:e}),h3:({children:e})=>l(t,{type:"h3",fontSize:"3xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h4:({children:e})=>l(t,{type:"h4",weight:"bold",fontSize:"2xl",className:"mb-8 leading-normal text-black",children:e}),h5:({children:e})=>l(t,{type:"h4",weight:"bold",fontSize:"xl",className:"mb-8 leading-normal text-black",children:e}),h6:({children:e})=>l(t,{type:"h4",weight:"bold",fontSize:"lg",className:"mb-8 leading-normal text-black",children:e}),normal:({children:e})=>l(r,{className:"mb-8 leading-relaxed",children:e}),blockquote:({children:e})=>s("blockquote",{className:"mb-6 italic leading-loose text-gray-500 px-14",children:["- ",e]})},code:({value:e})=>l("pre",{"data-language":e.language,children:l("code",{children:e.code})}),list:{bullet:({children:e})=>l("ul",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-disc",children:e}),number:({children:e})=>l("ol",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-decimal",children:e})},listItem:{bullet:({children:e})=>l("li",{className:"leading-relaxed",children:e}),number:({children:e})=>l("li",{className:"leading-relaxed",children:e})},marks:{strong:({children:e})=>l("strong",{children:e}),em:({children:e})=>l("em",{children:e}),code:({children:e})=>l("code",{children:e}),link:({children:e,value:a})=>l(n,{className:"hover:text-primary-foreground text-primary",href:a.href,target:"_blank",rel:"noopener noreferrer",children:e})},types:{addImage:({value:e})=>{var a,o,m;return l(i,{className:"w-full h-full mb-5",width:500,height:500,sizes:"(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 33vw",src:e==null?void 0:e.image,alt:(m=e==null?void 0:e.alt)!=null?m:(o=(a=e==null?void 0:e.image)==null?void 0:a.asset)==null?void 0:o._ref})}}};export{x as a};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";var
|
|
1
|
+
"use strict";var n=Object.defineProperty;var g=Object.getOwnPropertyDescriptor;var c=Object.getOwnPropertyNames;var b=Object.prototype.hasOwnProperty;var x=(e,t)=>{for(var a in t)n(e,a,{get:t[a],enumerable:!0})},p=(e,t,a,m)=>{if(t&&typeof t=="object"||typeof t=="function")for(let i of c(t))!b.call(e,i)&&i!==a&&n(e,i,{get:()=>t[i],enumerable:!(m=g(t,i))||m.enumerable});return e};var h=e=>p(n({},"__esModule",{value:!0}),e);var k={};x(k,{defaultBlockStyle:()=>f});module.exports=h(k);var o=require("@stackshift-ui/heading"),r=require("@stackshift-ui/image"),s=require("@stackshift-ui/link"),d=require("@stackshift-ui/text"),l=require("react/jsx-runtime"),f={block:{h1:({children:e})=>(0,l.jsx)(o.Heading,{fontSize:"5xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h2:({children:e})=>(0,l.jsx)(o.Heading,{type:"h2",weight:"bold",fontSize:"4xl",className:"mb-8 text-black",children:e}),h3:({children:e})=>(0,l.jsx)(o.Heading,{type:"h3",fontSize:"3xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h4:({children:e})=>(0,l.jsx)(o.Heading,{type:"h4",weight:"bold",fontSize:"2xl",className:"mb-8 leading-normal text-black",children:e}),h5:({children:e})=>(0,l.jsx)(o.Heading,{type:"h4",weight:"bold",fontSize:"xl",className:"mb-8 leading-normal text-black",children:e}),h6:({children:e})=>(0,l.jsx)(o.Heading,{type:"h4",weight:"bold",fontSize:"lg",className:"mb-8 leading-normal text-black",children:e}),normal:({children:e})=>(0,l.jsx)(d.Text,{className:"mb-8 leading-relaxed",children:e}),blockquote:({children:e})=>(0,l.jsxs)("blockquote",{className:"mb-6 italic leading-loose text-gray-500 px-14",children:["- ",e]})},code:({value:e})=>(0,l.jsx)("pre",{"data-language":e.language,children:(0,l.jsx)("code",{children:e.code})}),list:{bullet:({children:e})=>(0,l.jsx)("ul",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-disc",children:e}),number:({children:e})=>(0,l.jsx)("ol",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-decimal",children:e})},listItem:{bullet:({children:e})=>(0,l.jsx)("li",{className:"leading-relaxed",children:e}),number:({children:e})=>(0,l.jsx)("li",{className:"leading-relaxed",children:e})},marks:{strong:({children:e})=>(0,l.jsx)("strong",{children:e}),em:({children:e})=>(0,l.jsx)("em",{children:e}),code:({children:e})=>(0,l.jsx)("code",{children:e}),link:({children:e,value:t})=>(0,l.jsx)(s.Link,{className:"hover:text-primary-foreground text-primary",href:t.href,target:"_blank",rel:"noopener noreferrer",children:e})},types:{addImage:({value:e})=>{var t,a,m;return(0,l.jsx)(r.Image,{className:"w-full h-full mb-5",width:500,height:500,sizes:"(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 33vw",src:e==null?void 0:e.image,alt:(m=e==null?void 0:e.alt)!=null?m:(a=(t=e==null?void 0:e.image)==null?void 0:t.asset)==null?void 0:a._ref})}}};0&&(module.exports={defaultBlockStyle});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a}from"./chunk-
|
|
1
|
+
import{a}from"./chunk-MWQ5ZP4S.mjs";export{a as defaultBlockStyle};
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";var i=Object.defineProperty;var
|
|
2
|
+
"use strict";var i=Object.defineProperty;var y=Object.getOwnPropertyDescriptor;var k=Object.getOwnPropertyNames;var N=Object.prototype.hasOwnProperty;var w=(e,l)=>{for(var o in l)i(e,o,{get:l[o],enumerable:!0})},S=(e,l,o,a)=>{if(l&&typeof l=="object"||typeof l=="function")for(let m of k(l))!N.call(e,m)&&m!==o&&i(e,m,{get:()=>l[m],enumerable:!(a=y(l,m))||a.enumerable});return e};var T=e=>S(i({},"__esModule",{value:!0}),e);var H={};w(H,{Blockstyle:()=>d,defaultBlockStyle:()=>s});module.exports=T(H);var b=require("@portabletext/react"),r=require("@stackshift-ui/system");var n=require("@stackshift-ui/heading"),p=require("@stackshift-ui/image"),g=require("@stackshift-ui/link"),x=require("@stackshift-ui/text"),t=require("react/jsx-runtime"),s={block:{h1:({children:e})=>(0,t.jsx)(n.Heading,{fontSize:"5xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h2:({children:e})=>(0,t.jsx)(n.Heading,{type:"h2",weight:"bold",fontSize:"4xl",className:"mb-8 text-black",children:e}),h3:({children:e})=>(0,t.jsx)(n.Heading,{type:"h3",fontSize:"3xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h4:({children:e})=>(0,t.jsx)(n.Heading,{type:"h4",weight:"bold",fontSize:"2xl",className:"mb-8 leading-normal text-black",children:e}),h5:({children:e})=>(0,t.jsx)(n.Heading,{type:"h4",weight:"bold",fontSize:"xl",className:"mb-8 leading-normal text-black",children:e}),h6:({children:e})=>(0,t.jsx)(n.Heading,{type:"h4",weight:"bold",fontSize:"lg",className:"mb-8 leading-normal text-black",children:e}),normal:({children:e})=>(0,t.jsx)(x.Text,{className:"mb-8 leading-relaxed",children:e}),blockquote:({children:e})=>(0,t.jsxs)("blockquote",{className:"mb-6 italic leading-loose text-gray-500 px-14",children:["- ",e]})},code:({value:e})=>(0,t.jsx)("pre",{"data-language":e.language,children:(0,t.jsx)("code",{children:e.code})}),list:{bullet:({children:e})=>(0,t.jsx)("ul",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-disc",children:e}),number:({children:e})=>(0,t.jsx)("ol",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-decimal",children:e})},listItem:{bullet:({children:e})=>(0,t.jsx)("li",{className:"leading-relaxed",children:e}),number:({children:e})=>(0,t.jsx)("li",{className:"leading-relaxed",children:e})},marks:{strong:({children:e})=>(0,t.jsx)("strong",{children:e}),em:({children:e})=>(0,t.jsx)("em",{children:e}),code:({children:e})=>(0,t.jsx)("code",{children:e}),link:({children:e,value:l})=>(0,t.jsx)(g.Link,{className:"hover:text-primary-foreground text-primary",href:l.href,target:"_blank",rel:"noopener noreferrer",children:e})},types:{addImage:({value:e})=>{var l,o,a;return(0,t.jsx)(p.Image,{className:"w-full h-full mb-5",width:500,height:500,sizes:"(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 33vw",src:e==null?void 0:e.image,alt:(a=e==null?void 0:e.alt)!=null?a:(o=(l=e==null?void 0:e.image)==null?void 0:l.asset)==null?void 0:o._ref})}}};var f="Blockstyle",d=({children:e,className:l,as:o,content:a,...m})=>{let{[f]:h=r.DefaultComponent}=(0,r.useStackShiftUIComponents)();return(0,t.jsx)(h,{as:o,className:l,...m,children:a?(0,t.jsx)(b.PortableText,{value:a,components:s}):e})};d.displayName=f;0&&(module.exports={Blockstyle,defaultBlockStyle});
|
package/dist/index.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
"use strict";import{a as l}from"./chunk-
|
|
2
|
+
"use strict";import{a as l}from"./chunk-34BAENR7.mjs";import{a as e}from"./chunk-MWQ5ZP4S.mjs";export{l as Blockstyle,e as defaultBlockStyle};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@stackshift-ui/blockstyle",
|
|
3
3
|
"description": "",
|
|
4
|
-
"version": "6.0
|
|
4
|
+
"version": "6.1.0",
|
|
5
5
|
"private": false,
|
|
6
6
|
"sideEffects": false,
|
|
7
7
|
"main": "./dist/index.js",
|
|
@@ -29,20 +29,20 @@
|
|
|
29
29
|
"typescript": "^5.6.2",
|
|
30
30
|
"vite-tsconfig-paths": "^5.0.1",
|
|
31
31
|
"vitest": "^2.1.1",
|
|
32
|
-
"@stackshift-ui/
|
|
33
|
-
"@stackshift-ui/
|
|
32
|
+
"@stackshift-ui/eslint-config": "6.0.10",
|
|
33
|
+
"@stackshift-ui/typescript-config": "6.0.10"
|
|
34
34
|
},
|
|
35
35
|
"dependencies": {
|
|
36
36
|
"@portabletext/react": "^3.1.0",
|
|
37
|
-
"@stackshift-ui/scripts": "6.0
|
|
38
|
-
"@stackshift-ui/
|
|
39
|
-
"@stackshift-ui/
|
|
40
|
-
"@stackshift-ui/
|
|
41
|
-
"@stackshift-ui/
|
|
42
|
-
"@stackshift-ui/
|
|
37
|
+
"@stackshift-ui/scripts": "6.1.0",
|
|
38
|
+
"@stackshift-ui/system": "6.1.0",
|
|
39
|
+
"@stackshift-ui/image": "6.1.0",
|
|
40
|
+
"@stackshift-ui/heading": "6.1.0",
|
|
41
|
+
"@stackshift-ui/text": "6.1.0",
|
|
42
|
+
"@stackshift-ui/link": "6.1.0"
|
|
43
43
|
},
|
|
44
44
|
"peerDependencies": {
|
|
45
|
-
"@stackshift-ui/system": ">=
|
|
45
|
+
"@stackshift-ui/system": ">=7.0.0",
|
|
46
46
|
"@types/react": "16.8 - 19",
|
|
47
47
|
"next": "10 - 14",
|
|
48
48
|
"react": "16.8 - 19",
|
package/src/blockstyle.test.tsx
CHANGED
|
@@ -7,7 +7,7 @@ describe.concurrent("blockstyle", () => {
|
|
|
7
7
|
|
|
8
8
|
test("Common: Blockstyle - test if renders without errors", ({ expect }) => {
|
|
9
9
|
const clx = "blockStyle-class";
|
|
10
|
-
render(<Blockstyle className={clx} />);
|
|
10
|
+
render(<Blockstyle data-testid="div" className={clx} />);
|
|
11
11
|
|
|
12
12
|
expect(screen.getByTestId("div").classList).toContain(clx);
|
|
13
13
|
});
|
package/src/blockstyle.tsx
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { PortableText } from "@portabletext/react";
|
|
1
2
|
import { DefaultComponent, useStackShiftUIComponents } from "@stackshift-ui/system";
|
|
2
3
|
import type { ElementType, HTMLProps, ReactNode } from "react";
|
|
3
|
-
import { PortableText } from "@portabletext/react";
|
|
4
4
|
import { defaultBlockStyle } from "./defaultBlockStyle";
|
|
5
5
|
|
|
6
6
|
export interface BlockstyleProps extends Omit<HTMLProps<HTMLElement>, "as"> {
|
|
@@ -22,7 +22,7 @@ export const Blockstyle: React.FC<BlockstyleProps> = ({
|
|
|
22
22
|
const { [displayName]: Component = DefaultComponent } = useStackShiftUIComponents();
|
|
23
23
|
|
|
24
24
|
return (
|
|
25
|
-
<Component as={as} className={className} {...props}
|
|
25
|
+
<Component as={as} className={className} {...props}>
|
|
26
26
|
{content ? <PortableText value={content} components={defaultBlockStyle} /> : children}
|
|
27
27
|
</Component>
|
|
28
28
|
);
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
+
import { PortableTextComponents } from "@portabletext/react";
|
|
1
2
|
import { Heading } from "@stackshift-ui/heading";
|
|
2
|
-
import { Text } from "@stackshift-ui/text";
|
|
3
|
-
import { Link } from "@stackshift-ui/link";
|
|
4
3
|
import { Image } from "@stackshift-ui/image";
|
|
5
|
-
import {
|
|
4
|
+
import { Link } from "@stackshift-ui/link";
|
|
5
|
+
import { Text } from "@stackshift-ui/text";
|
|
6
6
|
|
|
7
7
|
export type MyPortableTextComponents = PortableTextComponents & {
|
|
8
8
|
code?: ({ value }: { value: { language?: string; code?: string } }) => JSX.Element;
|
|
@@ -11,21 +11,31 @@ export type MyPortableTextComponents = PortableTextComponents & {
|
|
|
11
11
|
export const defaultBlockStyle: MyPortableTextComponents = {
|
|
12
12
|
block: {
|
|
13
13
|
h1: ({ children }) => (
|
|
14
|
-
<Heading fontSize="
|
|
14
|
+
<Heading fontSize="5xl" weight="bold" className="mb-8 leading-normal text-black">
|
|
15
15
|
{children}
|
|
16
16
|
</Heading>
|
|
17
17
|
),
|
|
18
18
|
h2: ({ children }) => (
|
|
19
|
-
<Heading type="h2" weight="bold" fontSize="
|
|
19
|
+
<Heading type="h2" weight="bold" fontSize="4xl" className="mb-8 text-black">
|
|
20
20
|
{children}
|
|
21
21
|
</Heading>
|
|
22
22
|
),
|
|
23
23
|
h3: ({ children }) => (
|
|
24
|
-
<Heading type="h3" fontSize="
|
|
24
|
+
<Heading type="h3" fontSize="3xl" weight="bold" className="mb-8 leading-normal text-black">
|
|
25
25
|
{children}
|
|
26
26
|
</Heading>
|
|
27
27
|
),
|
|
28
28
|
h4: ({ children }) => (
|
|
29
|
+
<Heading type="h4" weight="bold" fontSize="2xl" className="mb-8 leading-normal text-black">
|
|
30
|
+
{children}
|
|
31
|
+
</Heading>
|
|
32
|
+
),
|
|
33
|
+
h5: ({ children }) => (
|
|
34
|
+
<Heading type="h4" weight="bold" fontSize="xl" className="mb-8 leading-normal text-black">
|
|
35
|
+
{children}
|
|
36
|
+
</Heading>
|
|
37
|
+
),
|
|
38
|
+
h6: ({ children }) => (
|
|
29
39
|
<Heading type="h4" weight="bold" fontSize="lg" className="mb-8 leading-normal text-black">
|
|
30
40
|
{children}
|
|
31
41
|
</Heading>
|
package/dist/chunk-GLR2G3MJ.mjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Heading as a}from"@stackshift-ui/heading";import{Text as i}from"@stackshift-ui/text";import{Link as r}from"@stackshift-ui/link";import{Image as n}from"@stackshift-ui/image";import{jsx as l,jsxs as s}from"react/jsx-runtime";var b={block:{h1:({children:e})=>l(a,{fontSize:"3xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h2:({children:e})=>l(a,{type:"h2",weight:"bold",fontSize:"2xl",className:"mb-8 text-black",children:e}),h3:({children:e})=>l(a,{type:"h3",fontSize:"xl",weight:"bold",className:"mb-8 leading-normal text-black",children:e}),h4:({children:e})=>l(a,{type:"h4",weight:"bold",fontSize:"lg",className:"mb-8 leading-normal text-black",children:e}),normal:({children:e})=>l(i,{className:"mb-8 leading-relaxed",children:e}),blockquote:({children:e})=>s("blockquote",{className:"mb-6 italic leading-loose text-gray-500 px-14",children:["- ",e]})},code:({value:e})=>l("pre",{"data-language":e.language,children:l("code",{children:e.code})}),list:{bullet:({children:e})=>l("ul",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-disc",children:e}),number:({children:e})=>l("ol",{className:"flex flex-col pl-10 mb-8 space-y-4 leading-relaxed list-decimal",children:e})},listItem:{bullet:({children:e})=>l("li",{className:"leading-relaxed",children:e}),number:({children:e})=>l("li",{className:"leading-relaxed",children:e})},marks:{strong:({children:e})=>l("strong",{children:e}),em:({children:e})=>l("em",{children:e}),code:({children:e})=>l("code",{children:e}),link:({children:e,value:t})=>l(r,{className:"hover:text-primary-foreground text-primary",href:t.href,target:"_blank",rel:"noopener noreferrer",children:e})},types:{addImage:({value:e})=>{var t,o,m;return l(n,{className:"w-full h-full mb-5",width:500,height:500,sizes:"(max-width: 768px) 100vw, (max-width: 1200px) 50vw, 33vw",src:e==null?void 0:e.image,alt:(m=e==null?void 0:e.alt)!=null?m:(o=(t=e==null?void 0:e.image)==null?void 0:t.asset)==null?void 0:o._ref})}}};export{b as a};
|
package/dist/chunk-INK7XA5Q.mjs
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as o}from"./chunk-GLR2G3MJ.mjs";import{DefaultComponent as r,useStackShiftUIComponents as c}from"@stackshift-ui/system";import{PortableText as i}from"@portabletext/react";import{jsx as s}from"react/jsx-runtime";var e="Blockstyle",y=({children:a,className:l,as:n,content:t,...m})=>{let{[e]:p=r}=c();return s(p,{as:n,className:l,...m,"data-testid":e,children:t?s(i,{value:t,components:o}):a})};y.displayName=e;export{y as a};
|