|
1 | | -import{jsx as n,jsxs as t,Fragment as i}from"react/jsx-runtime";import{C as r}from"./CodeBlock.d8e569ad.js";import{D as l,A as p,a as d,E as c}from"./Envelope.756a718a.js";import"react";import"./index.93441784.js";import"./index.6eef3859.js";import"./index.2ccb91f8.js";import"./index.978ae265.js";import"../client-entry.js";import"./chunk-FXLYF44B.3661c596.js";import"react-dom";import"./usePropsWithGroup.a30eaab0.js";import"./transform.3e3dfeca.js";import"./line.c32ceb13.js";import"./log.83f32a09.js";import"./index.185caace.js";import"./assertion.e9357fda.js";import"./useCommandAltClick.cec7174c.js";const T=void 0,I=[{id:"import",text:"Import",depth:2},{id:"usage",text:"Usage",depth:2},{id:"ahdsr-envelope",text:"AHDSR Envelope",depth:3},{id:"delay",text:"Delay",depth:3},{id:"api",text:"API",depth:2},{id:"envelope",text:"Envelope",depth:3},{id:"type-declarations",text:"Type Declarations",depth:2}],L="Envelope";function a(o){const e=Object.assign({h1:"h1",a:"a",p:"p",h2:"h2",h3:"h3",code:"code"},o.components);return t(i,{children:[t(e.h1,{id:"envelope",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#envelope",children:"#"}),"Envelope"]}),` |
2 | | -`,t(e.p,{children:["Envelope is a visual linear interactive component for ",n(e.a,{href:"https://en.wikipedia.org/wiki/Synthesizer#ADSR_envelope",target:"_blank",rel:"nofollow",children:"ADSR"})," envelope generator. You can use this component to control properties related to ADSR."]}),` |
3 | | -`,t(e.h2,{id:"import",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#import",children:"#"}),"Import"]}),` |
4 | | -`,n(r,{code:"import { Envelope } from 'echo-ui'"}),` |
5 | | -`,t(e.h2,{id:"usage",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#usage",children:"#"}),"Usage"]}),` |
| 1 | +import{jsx as n,jsxs as r,Fragment as i}from"react/jsx-runtime";import{C as o}from"./CodeBlock.d8e569ad.js";import{D as l,A as p,a as d,E as c}from"./Envelope.180234a0.js";import"react";import"./index.93441784.js";import"./index.6eef3859.js";import"./index.4d4f9478.js";import"./index.60566919.js";import"../client-entry.js";import"./chunk-FXLYF44B.3661c596.js";import"react-dom";import"./usePropsWithGroup.a30eaab0.js";import"./transform.3e3dfeca.js";import"./line.c32ceb13.js";import"./log.83f32a09.js";import"./index.b890c817.js";import"./assertion.e9357fda.js";import"./useCommandAltClick.cec7174c.js";const T=void 0,I=[{id:"import",text:"Import",depth:2},{id:"usage",text:"Usage",depth:2},{id:"ahdsr-envelope",text:"AHDSR Envelope",depth:3},{id:"delay",text:"Delay",depth:3},{id:"api",text:"API",depth:2},{id:"envelope",text:"Envelope",depth:3},{id:"type-declarations",text:"Type Declarations",depth:2}],L="Envelope";function a(t){const e=Object.assign({h1:"h1",a:"a",p:"p",h2:"h2",h3:"h3",code:"code"},t.components);return r(i,{children:[r(e.h1,{id:"envelope",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#envelope",children:"#"}),"Envelope"]}),` |
| 2 | +`,r(e.p,{children:["Envelope is a visual linear interactive component for ",n(e.a,{href:"https://en.wikipedia.org/wiki/Synthesizer#ADSR_envelope",target:"_blank",rel:"nofollow",children:"ADSR"})," envelope generator. You can use this component to control properties related to ADSR."]}),` |
| 3 | +`,r(e.h2,{id:"import",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#import",children:"#"}),"Import"]}),` |
| 4 | +`,n(o,{code:"import { Envelope } from 'echo-ui'"}),` |
| 5 | +`,r(e.h2,{id:"usage",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#usage",children:"#"}),"Usage"]}),` |
6 | 6 | `,n(l,{}),` |
7 | | -`,t(e.h3,{id:"ahdsr-envelope",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#ahdsr-envelope",children:"#"}),"AHDSR Envelope"]}),` |
| 7 | +`,r(e.h3,{id:"ahdsr-envelope",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#ahdsr-envelope",children:"#"}),"AHDSR Envelope"]}),` |
8 | 8 | `,n(p,{}),` |
9 | | -`,t(e.p,{children:["You can achieve ",n(e.a,{href:"https://support.output.com/hc/en-us/articles/4408642133399-AHDSR-Modulation",target:"_blank",rel:"nofollow",children:"AHDSR"})," envelope by passing the ",n(e.code,{children:"hold"})," parameter to the ",n(e.code,{children:"data"})," prop."]}),` |
10 | | -`,t(e.h3,{id:"delay",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#delay",children:"#"}),"Delay"]}),` |
| 9 | +`,r(e.p,{children:["You can achieve ",n(e.a,{href:"https://support.output.com/hc/en-us/articles/4408642133399-AHDSR-Modulation",target:"_blank",rel:"nofollow",children:"AHDSR"})," envelope by passing the ",n(e.code,{children:"hold"})," parameter to the ",n(e.code,{children:"data"})," prop."]}),` |
| 10 | +`,r(e.h3,{id:"delay",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#delay",children:"#"}),"Delay"]}),` |
11 | 11 | `,n(d,{}),` |
12 | | -`,t(e.p,{children:["By passing the ",n(e.code,{children:"delay"})," parameter to the ",n(e.code,{children:"data"})," prop, you can introduce delay points into the envelope."]}),` |
13 | | -`,t(e.h2,{id:"api",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#api",children:"#"}),"API"]}),` |
14 | | -`,t(e.h3,{id:"envelope-1",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#envelope-1",children:"#"}),"Envelope"]}),` |
| 12 | +`,r(e.p,{children:["By passing the ",n(e.code,{children:"delay"})," parameter to the ",n(e.code,{children:"data"})," prop, you can introduce delay points into the envelope."]}),` |
| 13 | +`,r(e.h2,{id:"api",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#api",children:"#"}),"API"]}),` |
| 14 | +`,r(e.h3,{id:"envelope-1",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#envelope-1",children:"#"}),"Envelope"]}),` |
15 | 15 | `,n(c,{}),` |
16 | | -`,t(e.h2,{id:"type-declarations",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#type-declarations",children:"#"}),"Type Declarations"]}),` |
17 | | -`,n(r,{code:`export interface EnvelopeProps extends React.HTMLAttributes<EnvelopeRef> { |
| 16 | +`,r(e.h2,{id:"type-declarations",children:[n(e.a,{className:"header-anchor","aria-hidden":"true",href:"#type-declarations",children:"#"}),"Type Declarations"]}),` |
| 17 | +`,n(o,{code:`export interface EnvelopeProps extends React.HTMLAttributes<EnvelopeRef> { |
18 | 18 | data: EnvelopeData |
19 | 19 | limits?: EnvelopeLimits |
20 | 20 | lineColor?: string |
@@ -42,69 +42,69 @@ export interface EnvelopeLimits { |
42 | 42 | } |
43 | 43 |
|
44 | 44 | export interface EnvelopeRef extends HTMLDivElement {} |
45 | | -`})]})}function M(o={}){const{wrapper:e}=o.components||{};return e?n(e,Object.assign({},o,{children:n(a,o)})):a(o)}const P="2024/1/15 18:45:10",B=`import { CodeBlock } from '../../src/components/CodeBlock.tsx' |
46 | | -import { Default, AHDSR, DADSR } from '../../src/components/UsageBox/Envelope.tsx' |
47 | | -import { EnvelopeAPITable } from '../../src/components/APITable/Envelope.tsx' |
48 | | -
|
49 | | -# Envelope |
50 | | -
|
51 | | -Envelope is a visual linear interactive component for [ADSR](https://en.wikipedia.org/wiki/Synthesizer#ADSR_envelope) envelope generator. You can use this component to control properties related to ADSR. |
52 | | -
|
53 | | -## Import |
54 | | -
|
55 | | -<CodeBlock code={\`import { Envelope } from 'echo-ui'\`} /> |
56 | | -
|
57 | | -## Usage |
58 | | -
|
59 | | -<Default /> |
60 | | -
|
61 | | -### AHDSR Envelope |
62 | | -
|
63 | | -<AHDSR /> |
64 | | -
|
65 | | -You can achieve [AHDSR](https://support.output.com/hc/en-us/articles/4408642133399-AHDSR-Modulation) envelope by passing the \`hold\` parameter to the \`data\` prop. |
66 | | -
|
67 | | -### Delay |
68 | | -
|
69 | | -<DADSR /> |
70 | | -
|
71 | | -By passing the \`delay\` parameter to the \`data\` prop, you can introduce delay points into the envelope. |
72 | | -
|
73 | | -## API |
74 | | -
|
75 | | -### Envelope |
76 | | -
|
77 | | -<EnvelopeAPITable /> |
78 | | -
|
79 | | -## Type Declarations |
80 | | -
|
81 | | -<CodeBlock code={\`export interface EnvelopeProps extends React.HTMLAttributes<EnvelopeRef> { |
82 | | - data: EnvelopeData |
83 | | - limits?: EnvelopeLimits |
84 | | - lineColor?: string |
85 | | - lineWidth?: number |
86 | | - nodeColor?: string |
87 | | - nodeSize?: number |
88 | | - onDataChange?: (data: EnvelopeData) => void |
89 | | -} |
90 | | -
|
91 | | -export interface EnvelopeData { |
92 | | - delay?: number |
93 | | - attack: number |
94 | | - decay: number |
95 | | - hold?: number |
96 | | - sustain: number |
97 | | - release: number |
98 | | -} |
99 | | -
|
100 | | -export interface EnvelopeLimits { |
101 | | - delay?: number |
102 | | - attack?: number |
103 | | - hold?: number |
104 | | - decay?: number |
105 | | - release?: number |
106 | | -} |
107 | | -
|
108 | | -export interface EnvelopeRef extends HTMLDivElement {} |
109 | | -\`} /> |
| 45 | +`})]})}function M(t={}){const{wrapper:e}=t.components||{};return e?n(e,Object.assign({},t,{children:n(a,t)})):a(t)}const P="2024/1/15 18:45:10",B=`import { CodeBlock } from '../../src/components/CodeBlock.tsx'\r |
| 46 | +import { Default, AHDSR, DADSR } from '../../src/components/UsageBox/Envelope.tsx'\r |
| 47 | +import { EnvelopeAPITable } from '../../src/components/APITable/Envelope.tsx'\r |
| 48 | +\r |
| 49 | +# Envelope\r |
| 50 | +\r |
| 51 | +Envelope is a visual linear interactive component for [ADSR](https://en.wikipedia.org/wiki/Synthesizer#ADSR_envelope) envelope generator. You can use this component to control properties related to ADSR.\r |
| 52 | +\r |
| 53 | +## Import\r |
| 54 | +\r |
| 55 | +<CodeBlock code={\`import { Envelope } from 'echo-ui'\`} />\r |
| 56 | +\r |
| 57 | +## Usage\r |
| 58 | +\r |
| 59 | +<Default />\r |
| 60 | +\r |
| 61 | +### AHDSR Envelope\r |
| 62 | +\r |
| 63 | +<AHDSR />\r |
| 64 | +\r |
| 65 | +You can achieve [AHDSR](https://support.output.com/hc/en-us/articles/4408642133399-AHDSR-Modulation) envelope by passing the \`hold\` parameter to the \`data\` prop.\r |
| 66 | +\r |
| 67 | +### Delay\r |
| 68 | +\r |
| 69 | +<DADSR />\r |
| 70 | +\r |
| 71 | +By passing the \`delay\` parameter to the \`data\` prop, you can introduce delay points into the envelope.\r |
| 72 | +\r |
| 73 | +## API\r |
| 74 | +\r |
| 75 | +### Envelope\r |
| 76 | +\r |
| 77 | +<EnvelopeAPITable />\r |
| 78 | +\r |
| 79 | +## Type Declarations\r |
| 80 | +\r |
| 81 | +<CodeBlock code={\`export interface EnvelopeProps extends React.HTMLAttributes<EnvelopeRef> {\r |
| 82 | + data: EnvelopeData\r |
| 83 | + limits?: EnvelopeLimits\r |
| 84 | + lineColor?: string\r |
| 85 | + lineWidth?: number\r |
| 86 | + nodeColor?: string\r |
| 87 | + nodeSize?: number\r |
| 88 | + onDataChange?: (data: EnvelopeData) => void\r |
| 89 | +}\r |
| 90 | +\r |
| 91 | +export interface EnvelopeData {\r |
| 92 | + delay?: number\r |
| 93 | + attack: number\r |
| 94 | + decay: number\r |
| 95 | + hold?: number\r |
| 96 | + sustain: number\r |
| 97 | + release: number\r |
| 98 | +}\r |
| 99 | +\r |
| 100 | +export interface EnvelopeLimits {\r |
| 101 | + delay?: number\r |
| 102 | + attack?: number\r |
| 103 | + hold?: number\r |
| 104 | + decay?: number\r |
| 105 | + release?: number\r |
| 106 | +}\r |
| 107 | +\r |
| 108 | +export interface EnvelopeRef extends HTMLDivElement {}\r |
| 109 | +\`} />\r |
110 | 110 | `;export{B as content,M as default,T as frontmatter,P as lastUpdatedTime,L as title,I as toc}; |
0 commit comments