import React, { HTMLAttributes } from "react";
export interface CwcLevelsElement extends HTMLElement {
readonly _currentLevel: number;
readonly _levels: any[];
_setCurrentLevel(currentLevel: number): void;
_setLevels(levelsDefinitions: { tooltip: string }[]): void;
}
export interface CwcMultiselectElement extends HTMLElement {
readonly _state: { [key: string]: boolean };
_buildChildrenFromJsonString(optionsAsJsonString: string);
_buildChildrenFromJsonObject(optionDefinitions: { name: string; label: string; onChange: ({ itemElement }) => void }[]);
}
export interface CwcMultiselectItemElement extends HTMLElement {
_getName(): string;
_isChecked(): boolean;
}
export interface CwcStepperElement extends HTMLElement {
readonly current: number;
}
export interface CwcStepperJsonElement extends HTMLElement {
readonly current: number;
readonly steps: string;
}
export interface CwcStepperItemElement extends HTMLElement {
readonly "is-last": boolean;
// TODO Consider to add an enum
status(): string;
}
export interface CwcModalElement extends HTMLElement {
readonly open: boolean;
showModal(): void;
hideModal(): void;
}
export interface CwcMonthPickerElement extends HTMLElement {
onUpdate?: (date: Date) => void;
}
// Web Component interfaces, so React knows about them and their HTML attributes
declare global {
namespace JSX {
interface IntrinsicElements {
"cwc-test": React.DetailedHTMLProps<
CwcTestAttributes,
HTMLElement
>;
"cwc-levels": React.DetailedHTMLProps<
CwcLevelsAttributes,
CwcLevelsElement
>;
"cwc-multiselect": React.DetailedHTMLProps<
CwcMultiselectAttributes,
CwcMultiselectElement
>;
"cwc-multiselect-item": React.DetailedHTMLProps<
CwcMultiselectItemAttributes,
CwcMultiselectItemElement
>;
"cwc-stepper": React.DetailedHTMLProps<
CwcStepperAttributes,
CwcStepperElement
>;
"cwc-stepper-json": React.DetailedHTMLProps<
CwcStepperJsonAttributes,
CwcStepperJsonElement
>;
"cwc-stepper-item": React.DetailedHTMLProps<
CwcStepperItemAttributes,
CwcStepperItemElement
>;
"cwc-modal": React.DetailedHTMLProps<
CwcModalAttributes,
CwcModalElement
>;
"cwc-month-picker": React.DetailedHTMLProps<
CwcMonthPickerAttributes,
CwcMonthPickerElement
>;
"cwc-login": React.DetailedHTMLProps<
CwcLoginAttributes,
HTMLElement
>;
"cwc-flipcard": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-textfield": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-uncomponentenuevp": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-componenttest": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-component123": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-test12344": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-test002": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-onemoretime": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
"cwc-angularTest": React.DetailedHTMLProps<
HTMLAttributes,
HTMLElement
>;
//END WEB COMPONENT INTERFACES - DO NOT REMOVE THIS LINE
}
interface CwcTestAttributes extends HTMLAttributes {
color: string;
}
interface CwcLevelsAttributes extends HTMLAttributes {
levels?: string;
currentlevel?: any;
}
interface CwcMultiselectAttributes extends HTMLAttributes {
options?: string;
required?: true | undefined;
disabled?: true | undefined;
nightmode?: true | undefined;
}
interface CwcMultiselectItemAttributes extends HTMLAttributes {
name: string;
nightmode?: true | undefined;
}
interface CwcStepperAttributes extends HTMLAttributes {
current: number;
}
interface CwcStepperJsonAttributes extends HTMLAttributes {
current: number;
steps: string;
}
interface CwcStepperItemAttributes extends HTMLAttributes {
"is-last"?: boolean;
}
interface CwcModalAttributes extends HTMLAttributes {
title?: string;
}
interface CwcMonthPickerAttributes extends HTMLAttributes {
initialdate?: string;
locale?: string;
"data-width"?: string;
}
interface CwcLoginAttributes extends HTMLAttributes {
title?: string;
description?: string;
prompt?: string;
buttontext?: string;
disabled?: boolean;
}
}
}
export { };