diff --git a/apps/docs/components/playground-utils/files.js b/apps/docs/components/playground-utils/files.js index f50b6f716..ea15f9178 100644 --- a/apps/docs/components/playground-utils/files.js +++ b/apps/docs/components/playground-utils/files.js @@ -21,7 +21,7 @@ module.exports = { [ "@stylexjs/babel-plugin", { - dev: true, + dev: false, stylexSheetName: "<>", genConditionalClasses: true, unstable_moduleResolution: { @@ -64,8 +64,8 @@ module.exports = { import * as React from 'react'; import * as stylex from "@stylexjs/stylex"; -export default function Card({ onClick, children, theme, variant, em = false }) { - const props = stylex.props(theme, styles.base, em && styles.emphasise, variantStyles[variant]); +export default function Card({ onClick, children, em = false }) { + const props = stylex.props(styles.base, em && styles.emphasise); } const styles = stylex.create({ @@ -82,16 +82,6 @@ const styles = stylex.create({ transform: "scale(1.1)", } }); - -const variantStyles = stylex.create({ - danger: { - backgroundColor: "red", - color: "white", - }, - primary: { - fontWeight: "bold", - }, -}); `, }, }, diff --git a/apps/docs/vercel.json b/apps/docs/vercel.json new file mode 100644 index 000000000..79353ba76 --- /dev/null +++ b/apps/docs/vercel.json @@ -0,0 +1,17 @@ +{ + "headers": [ + { + "source": "/(.*)", + "headers": [ + { + "key": "Cross-Origin-Embedder-Policy", + "value": "require-corp" + }, + { + "key": "Cross-Origin-Opener-Policy", + "value": "same-origin" + } + ] + } + ] +} \ No newline at end of file