@storybook/addon-highlight
Advanced tools
Comparing version 0.0.0-pr-28585-sha-af48f0d6 to 0.0.0-pr-28607-sha-54ec63fe
'use strict'; | ||
var coreEvents = require('storybook/internal/core-events'); | ||
var previewApi = require('storybook/internal/preview-api'); | ||
var global = require('@storybook/global'); | ||
var previewApi = require('storybook/internal/preview-api'); | ||
var coreEvents = require('storybook/internal/core-events'); | ||
@@ -7,0 +7,0 @@ var ADDON_ID="storybook/highlight",HIGHLIGHT_STYLE_ID="storybookHighlight",HIGHLIGHT=`${ADDON_ID}/add`,RESET_HIGHLIGHT=`${ADDON_ID}/reset`;var{document}=global.global,highlightStyle=(color="#FF4785",style="dashed")=>` |
{ | ||
"name": "@storybook/addon-highlight", | ||
"version": "0.0.0-pr-28585-sha-af48f0d6", | ||
"version": "0.0.0-pr-28607-sha-54ec63fe", | ||
"description": "Highlight DOM nodes within your stories", | ||
@@ -29,3 +29,2 @@ "keywords": [ | ||
"types": "./dist/index.d.ts", | ||
"node": "./dist/index.js", | ||
"import": "./dist/index.mjs", | ||
@@ -52,4 +51,4 @@ "require": "./dist/index.js" | ||
"scripts": { | ||
"check": "node --loader ../../../scripts/node_modules/esbuild-register/loader.js -r ../../../scripts/node_modules/esbuild-register/register.js ../../../scripts/prepare/check.ts", | ||
"prep": "node --loader ../../../scripts/node_modules/esbuild-register/loader.js -r ../../../scripts/node_modules/esbuild-register/register.js ../../../scripts/prepare/addon-bundle.ts" | ||
"check": "jiti ../../../scripts/prepare/check.ts", | ||
"prep": "jiti ../../../scripts/prepare/addon-bundle.ts" | ||
}, | ||
@@ -64,3 +63,3 @@ "dependencies": { | ||
"peerDependencies": { | ||
"storybook": "^0.0.0-pr-28585-sha-af48f0d6" | ||
"storybook": "^0.0.0-pr-28607-sha-54ec63fe" | ||
}, | ||
@@ -67,0 +66,0 @@ "publishConfig": { |
@@ -11,3 +11,3 @@ # Storybook Addon Highlight | ||
This addon requires Storybook 6.5 or later. Highlight is part of [essentials](https://storybook.js.org/docs/react/essentials) and so is installed in all new Storybooks by default. If you need to add it to your Storybook, you can run the following command: | ||
This addon requires Storybook 6.5 or later. Highlight is part of [essentials](https://storybook.js.org/docs/essentials) and so is installed in all new Storybooks by default. If you need to add it to your Storybook, you can run the following command: | ||
@@ -36,3 +36,2 @@ yarn: | ||
// .storybook/main.ts | ||
// Replace your-framework with the framework you are using (e.g., react-webpack5, vue3-vite) | ||
@@ -54,7 +53,5 @@ import type { StorybookConfig } from '@storybook/your-framework'; | ||
// MyComponent.stories.ts | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
import { useChannel } from '@storybook/preview-api'; | ||
import { HIGHLIGHT } from '@storybook/addon-highlight'; | ||
import { MyComponent } from './MyComponent'; | ||
@@ -88,7 +85,5 @@ | ||
// MyComponent.stories.ts|tsx | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
import { useChannel } from '@storybook/preview-api'; | ||
import { HIGHLIGHT, RESET_HIGHLIGHT } from '@storybook/addon-highlight'; | ||
import { MyComponent } from './MyComponent'; | ||
@@ -123,7 +118,5 @@ | ||
// MyComponent.stories.ts | ||
import type { Meta, StoryObj } from '@storybook/react'; | ||
import { useChannel } from '@storybook/preview-api'; | ||
import { HIGHLIGHT } from '@storybook/addon-highlight'; | ||
import { MyComponent } from './MyComponent'; | ||
@@ -130,0 +123,0 @@ |
Sorry, the diff of this file is not supported yet
9083
140