/**
 * HTML Node - Version 1
 * Work with HTML
 */


export interface HtmlV1Params {
  operation?: 'generateHtmlTemplate' | 'extractHtmlContent' | 'convertToHtmlTable';
/**
 * HTML template to render
 * @builderHint Use expressions to generate loops, reference data, etc. Does not support handlebars.
 * @displayOptions.show { operation: ["generateHtmlTemplate"] }
 */
    html?: string;
/**
 * If HTML should be read from binary or JSON data
 * @displayOptions.show { operation: ["extractHtmlContent"] }
 * @default json
 */
    sourceData?: 'binary' | 'json' | Expression<string>;
/**
 * Input Binary Field
 * @hint The name of the input binary field containing the file to be extracted
 * @displayOptions.show { operation: ["extractHtmlContent"], sourceData: ["binary"] }
 * @default data
 */
    dataPropertyName?: string | Expression<string> | PlaceholderValue;
/**
 * Extraction Values
 * @displayOptions.show { operation: ["extractHtmlContent"] }
 * @default {}
 */
    extractionValues?: {
        /** Values
     */
    values?: Array<{
      /** The key under which the extracted value should be saved
       */
      key?: string | Expression<string> | PlaceholderValue;
      /** The CSS selector to use
       */
      cssSelector?: string | Expression<string> | PlaceholderValue;
      /** What kind of data should be returned
       * @default text
       */
      returnValue?: 'attribute' | 'html' | 'text' | 'value' | Expression<string>;
      /** The name of the attribute to return the value off
       * @displayOptions.show { returnValue: ["attribute"] }
       */
      attribute?: string | Expression<string> | PlaceholderValue;
      /** Comma-separated list of selectors to skip in the text extraction
       * @displayOptions.show { returnValue: ["text"] }
       */
      skipSelectors?: string | Expression<string> | PlaceholderValue;
      /** Whether to return the values as an array so if multiple ones get found they also get returned separately. If not set all will be returned as a single string.
       * @default false
       */
      returnArray?: boolean | Expression<boolean>;
    }>;
  };
/**
 * Options
 * @displayOptions.show { operation: ["extractHtmlContent"] }
 * @default {}
 */
    options?: {
    /** Whether to remove automatically all spaces and newlines from the beginning and end of the values
     * @default true
     */
    trimValues?: boolean | Expression<boolean>;
    /** Whether to remove leading and trailing whitespaces, line breaks (newlines) and condense multiple consecutive whitespaces into a single space
     * @default true
     */
    cleanUpText?: boolean | Expression<boolean>;
    /** Whether to capitalize the headers
     * @default false
     */
    capitalize?: boolean | Expression<boolean>;
    /** Whether to use custom styling
     * @default false
     */
    customStyling?: boolean | Expression<boolean>;
    /** Caption to add to the table
     */
    caption?: string | Expression<string> | PlaceholderValue;
    /** Attributes to attach to the table
     */
    tableAttributes?: string | Expression<string> | PlaceholderValue;
    /** Attributes to attach to the table header
     */
    headerAttributes?: string | Expression<string> | PlaceholderValue;
    /** Attributes to attach to the table row
     */
    rowAttributes?: string | Expression<string> | PlaceholderValue;
    /** Attributes to attach to the table cell
     */
    cellAttributes?: string | Expression<string> | PlaceholderValue;
  };
}

interface HtmlV1NodeBase {
  type: 'n8n-nodes-base.html';
  version: 1;
}

export type HtmlV1ParamsNode = HtmlV1NodeBase & {
  config: NodeConfig<HtmlV1Params>;
};

export type HtmlV1Node = HtmlV1ParamsNode;