@jupyter/web-components
Version:
A component library for building extensions in Jupyter frontends.
63 lines (62 loc) • 2.52 kB
TypeScript
import { Anchor } from '@microsoft/fast-foundation';
import { ButtonAppearance } from '../button/index.js';
import { anchorStyles as styles } from './anchor.styles.js';
/**
* Types of anchor appearance.
* @public
*/
export type AnchorAppearance = ButtonAppearance | 'hypertext';
/**
* Anchor class
* @public
* @tagname jp-anchor
*/
declare class JupyterAnchor extends Anchor {
/**
* The appearance the anchor should have.
*
* @public
* @remarks
* HTML Attribute: appearance
*/
appearance?: AnchorAppearance;
appearanceChanged(oldValue: AnchorAppearance, newValue: AnchorAppearance): void;
connectedCallback(): void;
/**
* Applies 'icon-only' class when there is only an SVG in the default slot
*
* @internal
*
*/
defaultSlottedContentChanged(oldValue: any, newValue: any): void;
}
/**
* A function that returns a {@link @microsoft/fast-foundation#Anchor} registration for configuring the component with a DesignSystem.
* Implements {@link @microsoft/fast-foundation#anchorTemplate}
*
*
* @public
* @remarks
* Generates HTML Element: `<jp-anchor>`
*
* {@link https://developer.mozilla.org/en-US/docs/Web/API/ShadowRoot/delegatesFocus | delegatesFocus}
*/
export declare const jpAnchor: (overrideDefinition?: import("@microsoft/fast-foundation").OverrideFoundationElementDefinition<{
baseName: string;
baseClass: typeof Anchor;
template: import("@microsoft/fast-foundation").FoundationElementTemplate<import("@microsoft/fast-element").ViewTemplate<Anchor, any>, import("@microsoft/fast-foundation").AnchorOptions>;
styles: import("@microsoft/fast-foundation").FoundationElementTemplate<import("@microsoft/fast-element").ElementStyles, import("@microsoft/fast-foundation").AnchorOptions>;
shadowOptions: {
delegatesFocus: true;
};
}> | undefined) => import("@microsoft/fast-foundation").FoundationElementRegistry<{
baseName: string;
baseClass: typeof Anchor;
template: import("@microsoft/fast-foundation").FoundationElementTemplate<import("@microsoft/fast-element").ViewTemplate<Anchor, any>, import("@microsoft/fast-foundation").AnchorOptions>;
styles: import("@microsoft/fast-foundation").FoundationElementTemplate<import("@microsoft/fast-element").ElementStyles, import("@microsoft/fast-foundation").AnchorOptions>;
shadowOptions: {
delegatesFocus: true;
};
}, typeof JupyterAnchor>;
export { JupyterAnchor as Anchor };
export { styles as anchorStyles };