OudsLink constructor
- Key? key,
- required String label,
- @Deprecated('OudsLinkLayout is deprecated and will be removed in a future version. ' 'Use the dedicated OudsLink.icon, OudsLink.previous, OudsLink.next or ' 'OudsLink.external constructors instead.') OudsLinkLayout layout = OudsLinkLayout.textOnly,
- OudsLinkSize size = OudsLinkSize.defaultSize,
- OudsLinkDensity density = OudsLinkDensity.defaultDensity,
- VoidCallback? onPressed,
- String? icon,
Creates a text-only OudsLink.
label: The text displayed by the link. Required, non-empty; wraps onto multiple lines automatically if it doesn't fit the available width.layout: DeprecatedOudsLinkLayout(textOnly,textAndIcon,back,next). Use OudsLink.icon, OudsLink.previous, OudsLink.next or OudsLink.external instead. Defaults to OudsLinkLayout.textOnly.size: The size of the link, OudsLinkSize.defaultSize or OudsLinkSize.small, controlling text style and touch target dimensions. Defaults to OudsLinkSize.defaultSize.density: The density of the link, OudsLinkDensity.defaultDensity or OudsLinkDensity.compact, controlling the minimum height and block padding. Defaults to OudsLinkDensity.defaultDensity.onPressed: Callback invoked when the link is tapped or activated (keyboard/screen reader). Whennull, the link is rendered and announced as disabled and cannot receive focus.icon: Deprecated SVG asset path used to display a custom icon alongside thelabelwhen combined withlayout: OudsLinkLayout.textAndIcon. Use OudsLink.icon instead.
Implementation
const OudsLink({
super.key,
required this.label,
@Deprecated(
'OudsLinkLayout is deprecated and will be removed in a future version. '
'Use the dedicated OudsLink.icon, OudsLink.previous, OudsLink.next or '
'OudsLink.external constructors instead.',
)
this.layout = OudsLinkLayout.textOnly,
this.size = OudsLinkSize.defaultSize,
this.density = OudsLinkDensity.defaultDensity,
this.onPressed,
this.icon,
}) : _indicator = null,
tinted = true;