@storybook/preact-vite 8.0.0-alpha.6 → 8.0.0-alpha.8

Sign up to get free protection for your applications and to get access to all the features.
@@ -723,9 +723,6 @@ type StoryId = string;
723
723
  type ComponentTitle = string;
724
724
  type StoryName = string;
725
725
  type Tag = string;
726
- interface Parameters {
727
- [name: string]: any;
728
- }
729
726
 
730
727
  interface Plugin {
731
728
  (module: Program): Program;
@@ -2642,20 +2639,6 @@ type StoriesEntry = string | StoriesSpecifier;
2642
2639
  interface IndexerOptions {
2643
2640
  makeTitle: (userTitle?: string) => string;
2644
2641
  }
2645
- interface IndexedStory {
2646
- id: string;
2647
- name: string;
2648
- tags?: Tag[];
2649
- parameters?: Parameters;
2650
- }
2651
- interface IndexedCSFFile {
2652
- meta: {
2653
- id?: string;
2654
- title?: string;
2655
- tags?: Tag[];
2656
- };
2657
- stories: IndexedStory[];
2658
- }
2659
2642
  /**
2660
2643
  * FIXME: This is a temporary type to allow us to deprecate the old indexer API.
2661
2644
  * We should remove this type and the deprecated indexer API in 8.0.
@@ -2677,19 +2660,7 @@ type Indexer = BaseIndexer & {
2677
2660
  * @returns A promise that resolves to an array of {@link IndexInput} objects.
2678
2661
  */
2679
2662
  createIndex: (fileName: string, options: IndexerOptions) => Promise<IndexInput[]>;
2680
- /**
2681
- * @deprecated Use {@link index} instead
2682
- */
2683
- indexer?: never;
2684
- };
2685
- type DeprecatedIndexer = BaseIndexer & {
2686
- indexer: (fileName: string, options: IndexerOptions) => Promise<IndexedCSFFile>;
2687
- createIndex?: never;
2688
2663
  };
2689
- /**
2690
- * @deprecated Use {@link Indexer} instead
2691
- */
2692
- type StoryIndexer = Indexer | DeprecatedIndexer;
2693
2664
  /**
2694
2665
  * The base input for indexing a story or docs entry.
2695
2666
  */
@@ -2825,10 +2796,6 @@ interface CLIOptions {
2825
2796
  host?: string;
2826
2797
  initialPath?: string;
2827
2798
  exactPort?: boolean;
2828
- /**
2829
- * @deprecated Use 'staticDirs' Storybook Configuration option instead
2830
- */
2831
- staticDir?: string[];
2832
2799
  configDir?: string;
2833
2800
  https?: boolean;
2834
2801
  sslCa?: string[];
@@ -2990,11 +2957,6 @@ interface StorybookConfigRaw {
2990
2957
  * Filter args with a "target" on the type from the render function (EXPERIMENTAL)
2991
2958
  */
2992
2959
  argTypeTargetsV7?: boolean;
2993
- /**
2994
- * Warn when there is a pre-6.0 hierarchy separator ('.' / '|') in the story title.
2995
- * Will be removed in 7.0.
2996
- */
2997
- warnOnLegacyHierarchySeparator?: boolean;
2998
2960
  /**
2999
2961
  * Use legacy MDX1, to help smooth migration to 7.0
3000
2962
  */
@@ -3025,7 +2987,6 @@ interface StorybookConfigRaw {
3025
2987
  babelDefault?: TransformOptions;
3026
2988
  config?: Entry[];
3027
2989
  previewAnnotations?: Entry[];
3028
- storyIndexers?: StoryIndexer[];
3029
2990
  experimental_indexers?: Indexer[];
3030
2991
  docs?: DocsOptions;
3031
2992
  previewHead?: string;
@@ -3099,11 +3060,6 @@ interface StorybookConfig$1 {
3099
3060
  * Add additional scripts to run in the preview a la `.storybook/preview.js`
3100
3061
  */
3101
3062
  previewAnnotations?: PresetValue<StorybookConfigRaw['previewAnnotations']>;
3102
- /**
3103
- * Process CSF files for the story index.
3104
- * @deprecated use {@link experimental_indexers} instead
3105
- */
3106
- storyIndexers?: PresetValue<StorybookConfigRaw['storyIndexers']>;
3107
3063
  /**
3108
3064
  * Process CSF files for the story index.
3109
3065
  */
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- export { F as FrameworkOptions, S as StorybookConfig } from './index-9dd7a648.js';
1
+ export { F as FrameworkOptions, S as StorybookConfig } from './index-68189c40.js';
2
2
  import 'file-system-cache';
3
3
  import '@babel/core';
4
4
  import 'http';
package/dist/preset.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { P as PresetProperty, S as StorybookConfig } from './index-9dd7a648.js';
1
+ import { P as PresetProperty, S as StorybookConfig } from './index-68189c40.js';
2
2
  import 'file-system-cache';
3
3
  import '@babel/core';
4
4
  import 'http';
package/dist/preset.js CHANGED
@@ -1 +1 @@
1
- "use strict";var __create=Object.create;var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __getProtoOf=Object.getPrototypeOf,__hasOwnProp=Object.prototype.hasOwnProperty;var __export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0})},__copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toESM=(mod,isNodeMode,target)=>(target=mod!=null?__create(__getProtoOf(mod)):{},__copyProps(isNodeMode||!mod||!mod.__esModule?__defProp(target,"default",{value:mod,enumerable:!0}):target,mod)),__toCommonJS=mod=>__copyProps(__defProp({},"__esModule",{value:!0}),mod);var preset_exports={};__export(preset_exports,{core:()=>core,viteFinal:()=>viteFinal});module.exports=__toCommonJS(preset_exports);var import_builder_vite=require("@storybook/builder-vite"),import_preset_vite=__toESM(require("@preact/preset-vite")),import_path=require("path"),getAbsolutePath=input=>(0,import_path.dirname)(require.resolve((0,import_path.join)(input,"package.json"))),core={builder:getAbsolutePath("@storybook/builder-vite"),renderer:getAbsolutePath("@storybook/preact")},viteFinal=async config=>{let{plugins=[]}=config;return await(0,import_builder_vite.hasVitePlugins)(plugins,["vite:preact-jsx"])||plugins.push((0,import_preset_vite.default)()),config};0&&(module.exports={core,viteFinal});
1
+ "use strict";var __defProp=Object.defineProperty;var __getOwnPropDesc=Object.getOwnPropertyDescriptor;var __getOwnPropNames=Object.getOwnPropertyNames;var __hasOwnProp=Object.prototype.hasOwnProperty;var __export=(target,all)=>{for(var name in all)__defProp(target,name,{get:all[name],enumerable:!0})},__copyProps=(to,from,except,desc)=>{if(from&&typeof from=="object"||typeof from=="function")for(let key of __getOwnPropNames(from))!__hasOwnProp.call(to,key)&&key!==except&&__defProp(to,key,{get:()=>from[key],enumerable:!(desc=__getOwnPropDesc(from,key))||desc.enumerable});return to};var __toCommonJS=mod=>__copyProps(__defProp({},"__esModule",{value:!0}),mod);var preset_exports={};__export(preset_exports,{core:()=>core,viteFinal:()=>viteFinal});module.exports=__toCommonJS(preset_exports);var import_path=require("path"),getAbsolutePath=input=>(0,import_path.dirname)(require.resolve((0,import_path.join)(input,"package.json"))),core={builder:getAbsolutePath("@storybook/builder-vite"),renderer:getAbsolutePath("@storybook/preact")},viteFinal=async config=>config;0&&(module.exports={core,viteFinal});
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/preact-vite",
3
- "version": "8.0.0-alpha.6",
3
+ "version": "8.0.0-alpha.8",
4
4
  "description": "Storybook for Preact and Vite: Develop Preact components in isolation with Hot Reloading.",
5
5
  "keywords": [
6
6
  "storybook"
@@ -47,9 +47,8 @@
47
47
  "prep": "node --loader ../../../scripts/node_modules/esbuild-register/loader.js -r ../../../scripts/node_modules/esbuild-register/register.js ../../../scripts/prepare/bundle.ts"
48
48
  },
49
49
  "dependencies": {
50
- "@preact/preset-vite": "^2.0.0",
51
- "@storybook/builder-vite": "8.0.0-alpha.6",
52
- "@storybook/preact": "8.0.0-alpha.6"
50
+ "@storybook/builder-vite": "8.0.0-alpha.8",
51
+ "@storybook/preact": "8.0.0-alpha.8"
53
52
  },
54
53
  "devDependencies": {
55
54
  "@types/node": "^18.0.0",
@@ -58,7 +57,7 @@
58
57
  },
59
58
  "peerDependencies": {
60
59
  "preact": ">=10",
61
- "vite": "^3.0.0 || ^4.0.0 || ^5.0.0"
60
+ "vite": "^4.0.0 || ^5.0.0"
62
61
  },
63
62
  "engines": {
64
63
  "node": ">=16"