@arcgis/map-components
Version:
ArcGIS Map Components
97 lines (93 loc) • 4.38 kB
TypeScript
/// <reference types="@arcgis/core/interfaces.d.ts" />
/// <reference types="../../index.d.ts" />
import { ArcgisReferenceElement } from '../../utils/component-utils';
import { Nil } from '@arcgis/components-utils';
import { Use } from '@arcgis/components-controllers';
import { default as LinkChartLayoutSwitcherViewModel } from '@arcgis/core/widgets/LinkChartLayoutSwitcher/LinkChartLayoutSwitcherViewModel.js';
import { JsxNode, PublicLitElement as LitElement, TargetedEvent } from '@arcgis/lumina';
declare enum DiagramLayoutValues {
FORCE_DIRECTED = "organic-standard",
COMMUNITY = "organic-community",
SIMPLE = "basic-grid",
HIERARCHICAL = "hierarchical-bottom-to-top",
RADIAL_TREE = "radial-root-centric",
SMART_TREE = "tree-left-to-right",
GEOGRAPHIC = "geographic-organic-standard",
CHRONOLOGICAL_SINGLE = "chronological-mono-timeline",
CHRONOLOGICAL_MULTIPLE = "chronological-multi-timeline"
}
type DiagramLayoutType = `${DiagramLayoutValues}`;
declare const useLinkChartLayoutSwitcherViewModel: (component: import('@arcgis/components-controllers').StencilLifecycles & {
manager: import('@arcgis/components-controllers').ControllerManager;
el: HTMLElement;
autoDestroyDisabled?: boolean;
destroy?: () => Promise<void>;
} & Pick<LinkChartLayoutSwitcherViewModel, never> & {
reactiveUtils?: typeof __esri.reactiveUtils;
state?: "ready" | "loading" | "disabled" | undefined;
icon: Nil | string;
label: Nil | string;
referenceElement: ArcgisReferenceElement | Nil | string;
arcgisReady: import('@arcgis/components-controllers').EventEmitter;
position: __esri.UIPosition;
arcgisPropertyChange: import('@arcgis/components-controllers').EventEmitter<{
name: string;
}> | undefined;
el: HTMLElement & {
childElem?: HTMLElement & {
ownedBy?: HTMLElement;
};
view?: __esri.MapView | __esri.SceneView | undefined;
};
autoDestroyDisabled: boolean;
destroy: () => Promise<void>;
}, options?: {
editConstructorProperties(props: unknown): unknown;
} | undefined) => LinkChartLayoutSwitcherViewModel;
/** A component for use in link charts that allows users to switch between different layouts. See [documentation on layouts](https://enterprise.arcgis.com/en/knowledge/latest/knowledge-studio/change-the-layout-applied-to-a-link-chart.htm) for more details.
Note: Sign in to access the data in this demo, U/P: `viewer01`/`I68VGU^nMurF`
*/
export declare class ArcgisLinkChartLayoutSwitcher extends LitElement {
/**
* If true, the component will not be destroyed automatically when it is
* disconnected from the document. This is useful when you want to move the
* component to a different place on the page, or temporarily hide it. If this
* is set, make sure to call the \`destroy\` method when you are done to prevent
* memory leaks.
*/
autoDestroyDisabled: boolean;
/**
* Icon displayed in the widget's button.
*
* @see [Calcite Icon Search](https://developers.arcgis.com/calcite-design-system/icons/)
* @since 4.28
*/
icon: Nil | string;
/** The component's default label. */
label: Nil | string;
readonly layout: DiagramLayoutType;
position: __esri.UIPosition;
preventExtentUpdate: boolean;
referenceElement: ArcgisReferenceElement | Nil | string;
readonly state: "ready" | "loading" | "disabled";
/** Permanently destroy the component */
destroy(): Promise<void>;
/**
* Switches the layout of the link chart to the value provided.
*/
switchLayout(newLayout: "basic-grid" | "chronological-mono-timeline" | "chronological-multi-timeline" | "geographic-organic-standard" | "hierarchical-bottom-to-top" | "organic-community" | "organic-standard" | "radial-root-centric" | "tree-left-to-right"): Promise<void>;
/**
* Fires when component has completed the layout switch
*
* @example
* layoutswitcher.addEventListener("arcgisSwitchLayout", (event) => {
* console.log("Layout Switched");
* });
*/
readonly arcgisSwitchLayout: TargetedEvent<this, __esri.LinkChartLayoutSwitcherViewModelSwitchLayoutEvent>;
readonly arcgisPropertyChange: TargetedEvent<this, {
name: "state";
}>;
readonly arcgisReady: TargetedEvent<this, undefined>;
}
export {};