Skip to content

Commit

Permalink
refactor(themed): tidy up types (#10166)
Browse files Browse the repository at this point in the history
**Related Issue:** N/A

## Summary

* hides internal types
* makes `expectedValue` required
  • Loading branch information
jcfranco authored Aug 27, 2024
1 parent 4a59820 commit f2391ab
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/calcite-components/src/tests/commonTests/themed.ts
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ export function themed(componentTestSetup: ComponentTestSetup, tokens: Component
});
}

export type ContextSelectByAttr = { attribute: string; value: string | RegExp };
type ContextSelectByAttr = { attribute: string; value: string | RegExp };

type CSSProp = Extract<keyof CSSStyleDeclaration, string>;

Expand All @@ -183,7 +183,7 @@ type State = "press" | "hover" | "focus";
/**
* Describes a test target for themed components.
*/
export type TestTarget = {
type TestTarget = {
/**
* An object with target element and selector info.
*/
Expand All @@ -207,7 +207,7 @@ export type TestTarget = {
/**
* The expected value of the targetProp.
*/
expectedValue?: string;
expectedValue: string;

/**
* The associated component token.
Expand All @@ -230,7 +230,7 @@ type MappedCalciteCSSCustomProp = CalciteCSSCustomProp;
/**
* Describes a test selector for themed components.
*/
export type TestSelectToken = {
type TestSelectToken = {
/**
* The selector of the target element. When not provided, the component tag is used.
*/
Expand Down

0 comments on commit f2391ab

Please sign in to comment.