@storybook/csf 0.0.2--canary.29.77954d8.0 → 0.0.2--canary.52.d2acbe4.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. package/LICENSE +21 -0
  2. package/dist/index.d.ts +11 -1
  3. package/package.json +1 -1
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2022 CSF contributors
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/dist/index.d.ts CHANGED
@@ -39,6 +39,7 @@ declare type ComponentTitle = string;
39
39
  declare type StoryName = string;
40
40
  /** @deprecated */
41
41
  declare type StoryKind = ComponentTitle;
42
+ declare type Tag = string;
42
43
  interface StoryIdentifier {
43
44
  componentId: ComponentId;
44
45
  title: ComponentTitle;
@@ -48,6 +49,7 @@ interface StoryIdentifier {
48
49
  name: StoryName;
49
50
  /** @deprecated */
50
51
  story: StoryName;
52
+ tags: Tag[];
51
53
  }
52
54
  declare type Parameters = {
53
55
  [name: string]: any;
@@ -262,6 +264,10 @@ interface ComponentAnnotations<TFramework extends AnyFramework = AnyFramework, T
262
264
  * Function that is executed after the story is rendered.
263
265
  */
264
266
  play?: PlayFunction<TFramework, TArgs>;
267
+ /**
268
+ * Named tags for a story, used to filter stories in different contexts.
269
+ */
270
+ tags?: Tag[];
265
271
  }
266
272
  declare type StoryAnnotations<TFramework extends AnyFramework = AnyFramework, TArgs = Args, TRequiredArgs = Partial<TArgs>> = BaseAnnotations<TFramework, TArgs> & {
267
273
  /**
@@ -276,6 +282,10 @@ declare type StoryAnnotations<TFramework extends AnyFramework = AnyFramework, TA
276
282
  * Function that is executed after the story is rendered.
277
283
  */
278
284
  play?: PlayFunction<TFramework, TArgs>;
285
+ /**
286
+ * Named tags for a story, used to filter stories in different contexts.
287
+ */
288
+ tags?: Tag[];
279
289
  /** @deprecated */
280
290
  story?: Omit<StoryAnnotations<TFramework, TArgs>, 'story'>;
281
291
  } & ({} extends TRequiredArgs ? {
@@ -336,4 +346,4 @@ declare const parseKind: (kind: string, { rootSeparator, groupSeparator }: Separ
336
346
  groups: string[];
337
347
  };
338
348
 
339
- export { AnnotatedStoryFn, AnyFramework, ArgTypes, ArgTypesEnhancer, Args, ArgsEnhancer, ArgsFromMeta, ArgsStoryFn, BaseAnnotations, ComponentAnnotations, ComponentId, ComponentTitle, Conditional, DecoratorApplicator, DecoratorFunction, GlobalTypes, Globals, IncludeExcludeOptions, InputType, LegacyAnnotatedStoryFn, LegacyStoryAnnotationsOrFn, LegacyStoryFn, LoaderFunction, Parameters, PartialStoryFn, PlayFunction, PlayFunctionContext, ProjectAnnotations, SBArrayType, SBEnumType, SBIntersectionType, SBObjectType, SBOtherType, SBScalarType, SBType, SBUnionType, SeparatorOptions, StepFunction, StepLabel, StepRunner, StoryAnnotations, StoryAnnotationsOrFn, StoryContext, StoryContextForEnhancers, StoryContextForLoaders, StoryContextUpdate, StoryFn, StoryId, StoryIdentifier, StoryKind, StoryName, StrictArgTypes, StrictGlobalTypes, StrictInputType, ViewMode, includeConditionalArg, isExportStory, parseKind, sanitize, storyNameFromExport, toId };
349
+ export { AnnotatedStoryFn, AnyFramework, ArgTypes, ArgTypesEnhancer, Args, ArgsEnhancer, ArgsFromMeta, ArgsStoryFn, BaseAnnotations, ComponentAnnotations, ComponentId, ComponentTitle, Conditional, DecoratorApplicator, DecoratorFunction, GlobalTypes, Globals, IncludeExcludeOptions, InputType, LegacyAnnotatedStoryFn, LegacyStoryAnnotationsOrFn, LegacyStoryFn, LoaderFunction, Parameters, PartialStoryFn, PlayFunction, PlayFunctionContext, ProjectAnnotations, SBArrayType, SBEnumType, SBIntersectionType, SBObjectType, SBOtherType, SBScalarType, SBType, SBUnionType, SeparatorOptions, StepFunction, StepLabel, StepRunner, StoryAnnotations, StoryAnnotationsOrFn, StoryContext, StoryContextForEnhancers, StoryContextForLoaders, StoryContextUpdate, StoryFn, StoryId, StoryIdentifier, StoryKind, StoryName, StrictArgTypes, StrictGlobalTypes, StrictInputType, Tag, ViewMode, includeConditionalArg, isExportStory, parseKind, sanitize, storyNameFromExport, toId };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@storybook/csf",
3
- "version": "0.0.2--canary.29.77954d8.0",
3
+ "version": "0.0.2--canary.52.d2acbe4.0",
4
4
  "description": "Component Story Format (CSF) utilities",
5
5
  "keywords": [
6
6
  "storybook",