@remotion/rough-notation 4.0.490

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/README.md ADDED
@@ -0,0 +1,18 @@
1
+ # @remotion/rough-notation
2
+
3
+ Rough annotation primitives for Remotion
4
+
5
+ [![NPM Downloads](https://img.shields.io/npm/dm/@remotion/rough-notation.svg?style=flat&color=black&label=Downloads)](https://npmcharts.com/compare/@remotion/rough-notation?minimal=true)
6
+
7
+ ## Installation
8
+
9
+ ```bash
10
+ npm install @remotion/rough-notation --save-exact
11
+ ```
12
+
13
+ When installing a Remotion package, make sure to align the version of all `remotion` and `@remotion/*` packages to the same version.
14
+ Remove the `^` character from the version number to use the exact version.
15
+
16
+ ## Usage
17
+
18
+ See the [documentation](https://www.remotion.dev/docs/rough-notation) for more information.
@@ -0,0 +1,34 @@
1
+ import React from 'react';
2
+ import { type InteractiveBaseProps, type InteractivitySchema } from 'remotion';
3
+ import type { BoxConfig, BracketAnnotationConfig, CircleConfig, CrossedOffConfig, CurveAnnotationOptions, HighlightConfig, SharedRoughAnnotationOptions, StrikeThroughConfig, UnderlineConfig } from './types';
4
+ type SharedAnnotationComponentProps = Readonly<{
5
+ readonly children: React.ReactNode;
6
+ readonly progress: number;
7
+ readonly seed?: number;
8
+ readonly disabled?: boolean;
9
+ readonly style?: React.CSSProperties;
10
+ } & SharedRoughAnnotationOptions>;
11
+ type AnnotationInteractiveProps<Config> = SharedAnnotationComponentProps & Readonly<Config> & InteractiveBaseProps;
12
+ export type HighlightProps = AnnotationInteractiveProps<HighlightConfig>;
13
+ export type UnderlineProps = AnnotationInteractiveProps<UnderlineConfig>;
14
+ export type StrikeThroughProps = AnnotationInteractiveProps<StrikeThroughConfig>;
15
+ export type CrossedOffProps = AnnotationInteractiveProps<CrossedOffConfig>;
16
+ export type BoxProps = AnnotationInteractiveProps<BoxConfig>;
17
+ export type BracketProps = AnnotationInteractiveProps<BracketAnnotationConfig>;
18
+ export type CircleProps = AnnotationInteractiveProps<CircleConfig & CurveAnnotationOptions>;
19
+ export declare const highlightSchema: InteractivitySchema;
20
+ export declare const underlineSchema: InteractivitySchema;
21
+ export declare const strikeThroughSchema: InteractivitySchema;
22
+ export declare const crossedOffSchema: InteractivitySchema;
23
+ export declare const boxSchema: InteractivitySchema;
24
+ export declare const bracketSchema: InteractivitySchema;
25
+ export declare const circleSchema: InteractivitySchema;
26
+ declare const annotationSchemas: InteractivitySchema[];
27
+ export { annotationSchemas };
28
+ export declare const Highlight: React.FC<HighlightProps>;
29
+ export declare const Underline: React.FC<UnderlineProps>;
30
+ export declare const StrikeThrough: React.FC<StrikeThroughProps>;
31
+ export declare const CrossedOff: React.FC<CrossedOffProps>;
32
+ export declare const Box: React.FC<BoxProps>;
33
+ export declare const Bracket: React.FC<BracketProps>;
34
+ export declare const Circle: React.FC<CircleProps>;
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ import { type AnnotationConfig, type RoughAnnotationOptions } from './types';
3
+ type ChildrenProps = {
4
+ readonly children: React.ReactNode;
5
+ };
6
+ type TrackerProps = ChildrenProps & {
7
+ readonly style?: React.CSSProperties;
8
+ };
9
+ type AnnotationProps = Readonly<AnnotationConfig & {
10
+ seed?: number;
11
+ progress: number;
12
+ } & RoughAnnotationOptions>;
13
+ export declare const createAnnotation: () => {
14
+ Container: React.FC<ChildrenProps>;
15
+ Tracker: React.FC<TrackerProps>;
16
+ Annotation: React.FC<AnnotationProps>;
17
+ };
18
+ export {};
@@ -0,0 +1,8 @@
1
+ export type Size = {
2
+ readonly width: number;
3
+ readonly height: number;
4
+ readonly left: number;
5
+ readonly top: number;
6
+ readonly refresh: () => void;
7
+ };
8
+ export declare const useElementSize: (ref: import("react").RefObject<HTMLElement | null>) => Size | null;