@webflow/designer-extension-typings 2.0.19 → 2.0.21
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/package.json +1 -1
- package/styles.d.ts +4 -4
- package/variables.d.ts +10 -5
package/package.json
CHANGED
package/styles.d.ts
CHANGED
|
@@ -170,10 +170,10 @@ interface Style {
|
|
|
170
170
|
* @param options - Options to remove variable modes based on breakpoints and pseudo classes / states.
|
|
171
171
|
* @example
|
|
172
172
|
* ```ts
|
|
173
|
-
* await
|
|
174
|
-
*
|
|
175
|
-
*
|
|
176
|
-
*
|
|
173
|
+
* const collection = await webflow.getVariableCollectionById('collection-id');
|
|
174
|
+
* const mode = await collection.getVariableModeByName('Dark');
|
|
175
|
+
* const modeTwo = await collection.getVariableModeByName('Light');
|
|
176
|
+
* await myStyle.removeVariableModes([mode, modeTwo]);
|
|
177
177
|
* ```
|
|
178
178
|
*/
|
|
179
179
|
removeVariableModes(
|
package/variables.d.ts
CHANGED
|
@@ -510,23 +510,28 @@ interface VariableCollection {
|
|
|
510
510
|
getAllVariables(): Promise<Array<Variable>>;
|
|
511
511
|
createColorVariable(
|
|
512
512
|
name: string,
|
|
513
|
-
value: string | ColorVariable | CustomValue
|
|
513
|
+
value: string | ColorVariable | CustomValue,
|
|
514
|
+
modes?: {[key: VariableModeId]: string | ColorVariable | CustomValue}
|
|
514
515
|
): Promise<ColorVariable>;
|
|
515
516
|
createSizeVariable(
|
|
516
517
|
name: string,
|
|
517
|
-
value: SizeValue | SizeVariable | CustomValue
|
|
518
|
+
value: SizeValue | SizeVariable | CustomValue,
|
|
519
|
+
modes?: {[key: VariableModeId]: SizeValue | SizeVariable | CustomValue}
|
|
518
520
|
): Promise<SizeVariable>;
|
|
519
521
|
createNumberVariable(
|
|
520
522
|
name: string,
|
|
521
|
-
value: number | NumberVariable | CustomValue
|
|
523
|
+
value: number | NumberVariable | CustomValue,
|
|
524
|
+
modes?: {[key: VariableModeId]: number | NumberVariable | CustomValue}
|
|
522
525
|
): Promise<NumberVariable>;
|
|
523
526
|
createPercentageVariable(
|
|
524
527
|
name: string,
|
|
525
|
-
value: number | PercentageVariable | CustomValue
|
|
528
|
+
value: number | PercentageVariable | CustomValue,
|
|
529
|
+
modes?: {[key: VariableModeId]: number | PercentageVariable | CustomValue}
|
|
526
530
|
): Promise<PercentageVariable>;
|
|
527
531
|
createFontFamilyVariable(
|
|
528
532
|
name: string,
|
|
529
|
-
value: string | FontFamilyVariable | CustomValue
|
|
533
|
+
value: string | FontFamilyVariable | CustomValue,
|
|
534
|
+
modes?: {[key: VariableModeId]: string | FontFamilyVariable | CustomValue}
|
|
530
535
|
): Promise<FontFamilyVariable>;
|
|
531
536
|
/**
|
|
532
537
|
* Sets the name of the variable collection.
|