- {{ description || null }}
+
See {{ relatedPropValue(relatedProp) }}
diff --git a/components/doc/DocSections.vue b/components/doc/DocSections.vue
index f04e5cf42..547ccd393 100644
--- a/components/doc/DocSections.vue
+++ b/components/doc/DocSections.vue
@@ -4,7 +4,7 @@
- {{ doc.description }}
+
diff --git a/components/doc/helpers/PTHelper.js b/components/doc/helpers/index.js
similarity index 59%
rename from components/doc/helpers/PTHelper.js
rename to components/doc/helpers/index.js
index b6c79714e..1aba2b44b 100644
--- a/components/doc/helpers/PTHelper.js
+++ b/components/doc/helpers/index.js
@@ -1,6 +1,7 @@
import APIDocs from '@/doc/common/apidoc/index.json';
+import { $dt } from 'primevue/themes';
-export const getPTOption = (name) => {
+export const getPTOptions = (name) => {
const { props } = APIDocs[name.toLowerCase()].interfaces.values[`${name}PassThroughOptions`] || APIDocs[name.toLowerCase()].interfaces.values[`${name}DirectivePassThroughOptions`];
const options = APIDocs[name.toLowerCase()].interfaces.values[`${name}PassThroughMethodOptions`];
let data = [];
@@ -35,3 +36,41 @@ export const getPTOption = (name) => {
return data;
};
+
+export const getStyleOptions = (name) => {
+ const { members } = APIDocs[name.toLowerCase() + 'style']?.enumerations?.values?.[`${name}Classes`];
+ let data = [];
+
+ for (const member of members) {
+ const { name, value, description } = member;
+
+ data.push({
+ class: value.replaceAll('"', ''),
+ section: name,
+ description
+ });
+ }
+
+ return data;
+};
+
+export const getTokenOptions = (preset, name) => {
+ const values = APIDocs[`${preset.toLowerCase()}/${name.toLowerCase()}`]?.tokens?.values;
+ let data = [];
+
+ for (const [key, value] of Object.entries(values)) {
+ for (const tokens of value?.props) {
+ const { token, description } = tokens;
+ const designToken = $dt(token);
+
+ data.push({
+ token,
+ variable: designToken.name,
+ section: key.toLowerCase(),
+ description: description
+ });
+ }
+ }
+
+ return data;
+};
diff --git a/components/lib/inputtext/style/InputTextStyle.d.ts b/components/lib/inputtext/style/InputTextStyle.d.ts
index 94ac26ec8..658698e90 100644
--- a/components/lib/inputtext/style/InputTextStyle.d.ts
+++ b/components/lib/inputtext/style/InputTextStyle.d.ts
@@ -10,6 +10,9 @@
import { BaseStyle } from '../../base/style';
export enum InputTextClasses {
+ /**
+ * The class of input element
+ */
root = 'p-inputtext'
}
diff --git a/components/lib/themes/aura/index.d.ts b/components/lib/themes/aura/index.d.ts
index e69de29bb..ba3523d4d 100644
--- a/components/lib/themes/aura/index.d.ts
+++ b/components/lib/themes/aura/index.d.ts
@@ -0,0 +1,89 @@
+/**
+ *
+ * [Live Demo](https://www.primevue.org/)
+ *
+ * @module aura
+ *
+ */
+export interface ColorSchemeDesignToken {
+ colorScheme?: {
+ light?: Omit;
+ dark?: Omit;
+ };
+}
+
+export interface PaletteDesignToken {
+ 50?: string;
+ 100?: string;
+ 200?: string;
+ 300?: string;
+ 400?: string;
+ 500?: string;
+ 600?: string;
+ 700?: string;
+ 800?: string;
+ 900?: string;
+ 950?: string;
+}
+
+export interface PrimitiveDesignTokens {
+ borderRadius?: {
+ none?: string;
+ xs?: string;
+ sm?: string;
+ md?: string;
+ lg?: string;
+ xl?: string;
+ };
+ emerald?: PaletteDesignToken;
+ green?: PaletteDesignToken;
+ lime?: PaletteDesignToken;
+ red?: PaletteDesignToken;
+ orange?: PaletteDesignToken;
+ amber?: PaletteDesignToken;
+ yellow?: PaletteDesignToken;
+ teal?: PaletteDesignToken;
+ cyan?: PaletteDesignToken;
+ sky?: PaletteDesignToken;
+ blue?: PaletteDesignToken;
+ indigo?: PaletteDesignToken;
+ violet?: PaletteDesignToken;
+ purple?: PaletteDesignToken;
+ fuchsia?: PaletteDesignToken;
+ pink?: PaletteDesignToken;
+ rose?: PaletteDesignToken;
+ slate?: PaletteDesignToken;
+ gray?: PaletteDesignToken;
+ zinc?: PaletteDesignToken;
+ neutral?: PaletteDesignToken;
+ stone?: PaletteDesignToken;
+ [key: string]: any;
+}
+
+export interface SemanticDesignTokens {
+ transitionDuration?: string;
+ focusRing?: {
+ width?: string;
+ style?: string;
+ color?: string;
+ offset?: string;
+ shadow?: string;
+ };
+ iconSize?: string;
+ anchorGutter?: string;
+ primary?: PaletteDesignToken;
+ formField: {
+ paddingX?: string;
+ paddingY?: string;
+ borderRadius?: string;
+ focusRing?: {
+ width?: string;
+ style?: string;
+ color?: string;
+ offset?: string;
+ shadow?: string;
+ };
+ };
+ // @todo
+ [key: string]: any;
+}
diff --git a/components/lib/themes/aura/inputtext/index.d.ts b/components/lib/themes/aura/inputtext/index.d.ts
index e69de29bb..ea2cc3977 100644
--- a/components/lib/themes/aura/inputtext/index.d.ts
+++ b/components/lib/themes/aura/inputtext/index.d.ts
@@ -0,0 +1,164 @@
+/**
+ *
+ * InputText renders a text field to enter data.
+ *
+ * [Live Demo](https://www.primevue.org/inputtext/)
+ *
+ * @module aura/inputtext
+ *
+ */
+import { ColorSchemeDesignToken } from '..';
+
+/**
+ * Defines all sections of design tokens
+ */
+export namespace InputTextDesignToken {
+ /**
+ * Tokens of the root section
+ */
+ export interface Root {
+ /**
+ * Background of an input field
+ *
+ * @designToken inputtext.background
+ */
+ background?: string;
+ /**
+ * Background of an input field when disabled
+ *
+ * @designToken inputtext.disabled.background
+ */
+ disabledBackground?: string;
+ /**
+ * Background of an input field when filled mode
+ *
+ * @designToken inputtext.filled.background
+ */
+ filledBackground?: string;
+ /**
+ * Background of an input field on the focus state of filled mode
+ *
+ * @designToken inputtext.filled.focus.background
+ */
+ filledFocusBackground?: string;
+ /**
+ * Border color of an input field
+ *
+ * @designToken inputtext.border.color
+ */
+ borderColor?: string;
+ /**
+ * Border color of an input field on the hover state
+ *
+ * @designToken inputtext.hover.border.color
+ */
+ hoverBorderColor?: string;
+ /**
+ * Border color of an input field on the focus state
+ *
+ * @designToken inputtext.focus.border.color
+ */
+ focusBorderColor?: string;
+ /**
+ * Border color of an input field when invalid
+ *
+ * @designToken inputtext.invalid.border.color
+ */
+ invalidBorderColor?: string;
+ /**
+ * Color of an input field
+ *
+ * @designToken inputtext.color
+ */
+ color?: string;
+ /**
+ * Color of an input field when disabled
+ *
+ * @designToken inputtext.disabled.color
+ */
+ disabledColor?: string;
+ /**
+ * Placeholder color of an input field
+ *
+ * @designToken inputtext.placeholder.color
+ */
+ placeholderColor?: string;
+ /**
+ * Shadow of an input field
+ *
+ * @designToken inputtext.shadow
+ */
+ shadow?: string;
+ /**
+ * Padding right and left of an input field
+ *
+ * @designToken inputtext.padding.x
+ */
+ paddingX?: string;
+ /**
+ * Padding top and bottom of an input field
+ *
+ * @designToken inputtext.padding.y
+ */
+ paddingY?: string;
+ /**
+ * Border radius of an input field
+ *
+ * @designToken inputtext.border.radius
+ */
+ borderRadius?: string;
+ /**
+ * Outline of an input field on the focus state
+ */
+ focusRing?: {
+ /**
+ * Outline width of an input field on the focus state
+ *
+ * @designToken inputtext.focus.ring.width
+ */
+ width?: string;
+ /**
+ * Outline style of an input field on the focus state
+ *
+ * @designToken inputtext.focus.ring.style
+ */
+ style?: string;
+ /**
+ * Outline color of an input field on the focus state
+ *
+ * @designToken inputtext.focus.ring.color
+ */
+ color?: string;
+ /**
+ * Outline offset of an input field on the focus state
+ *
+ * @designToken inputtext.focus.ring.offset
+ */
+ offset?: string;
+ /**
+ * Shadow of an input field on the focus state
+ *
+ * @designToken inputtext.focus.ring.shadow
+ */
+ shadow?: string;
+ };
+ }
+}
+
+/**
+ * **PrimeVue - InputText**
+ *
+ * _InputText renders a text field to enter data._
+ *
+ * [Live Demo](https://www.primevue.org/inputtext/)
+ * --- ---
+ * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
+ *
+ * @group DesignTokens
+ */
+export interface InputTextDesignTokens extends ColorSchemeDesignToken {
+ /**
+ * Used to pass tokens of the root section
+ */
+ root?: InputTextDesignToken.Root;
+}
diff --git a/components/lib/themes/lara/inputtext/index.d.ts b/components/lib/themes/lara/inputtext/index.d.ts
index e69de29bb..e4b251adf 100644
--- a/components/lib/themes/lara/inputtext/index.d.ts
+++ b/components/lib/themes/lara/inputtext/index.d.ts
@@ -0,0 +1,56 @@
+/**
+ *
+ * InputText renders a text field to enter data.
+ *
+ * [Live Demo](https://www.primevue.org/inputtext/)
+ *
+ * @module lara/inputtext
+ *
+ */
+
+/**
+ * Defines all sections of design tokens
+ */
+export namespace InputTextDesignToken {
+ /**
+ * Tokens of the root section
+ */
+ export interface Root {
+ /**
+ * Background of an input field
+ *
+ * @designToken inputtext.background
+ */
+ background?: string;
+ /**
+ * Background of an input field when disabled
+ *
+ * @designToken inputtext.disabled.background
+ */
+ disabledBackground?: string;
+ /**
+ * Background of an input field when filled mode
+ *
+ * @designToken inputtext.filled.background
+ */
+ filledBackground?: string;
+ }
+}
+
+/**
+ * **PrimeVue - InputText**
+ *
+ * _InputText renders a text field to enter data._
+ *
+ * [Live Demo](https://www.primevue.org/inputtext/)
+ * --- ---
+ * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
+ *
+ * @group DesignTokens
+ */
+export interface InputTextDesignTokens {
+ /**
+ * Used to pass tokens of the root section
+ */
+ root?: InputTextDesignToken.Root;
+}
diff --git a/components/lib/themes/nora/inputtext/index.d.ts b/components/lib/themes/nora/inputtext/index.d.ts
index e69de29bb..d6493b461 100644
--- a/components/lib/themes/nora/inputtext/index.d.ts
+++ b/components/lib/themes/nora/inputtext/index.d.ts
@@ -0,0 +1,44 @@
+/**
+ *
+ * InputText renders a text field to enter data.
+ *
+ * [Live Demo](https://www.primevue.org/inputtext/)
+ *
+ * @module nora/inputtext
+ *
+ */
+
+/**
+ * Defines all sections of design tokens
+ */
+export namespace InputTextDesignToken {
+ /**
+ * Tokens of the root section
+ */
+ export interface Root {
+ /**
+ * Background of an input field
+ *
+ * @designToken inputtext.background
+ */
+ background?: string;
+ }
+}
+
+/**
+ * **PrimeVue - InputText**
+ *
+ * _InputText renders a text field to enter data._
+ *
+ * [Live Demo](https://www.primevue.org/inputtext/)
+ * --- ---
+ * ![PrimeVue](https://primefaces.org/cdn/primevue/images/logo-100.png)
+ *
+ * @group DesignTokens
+ */
+export interface InputTextDesignTokens {
+ /**
+ * Used to pass tokens of the root section
+ */
+ root?: InputTextDesignToken.Root;
+}
diff --git a/doc/accordion/pt/index.vue b/doc/accordion/pt/index.vue
index 4655aec33..172fd99cd 100644
--- a/doc/accordion/pt/index.vue
+++ b/doc/accordion/pt/index.vue
@@ -10,7 +10,7 @@
diff --git a/doc/knob/pt/index.vue b/doc/knob/pt/index.vue
index e21667a61..fded4fef3 100644
--- a/doc/knob/pt/index.vue
+++ b/doc/knob/pt/index.vue
@@ -10,7 +10,7 @@