UNPKG

flowus-api-sdk

Version:

Official TypeScript/JavaScript SDK for FlowUs API - Create, manage, and interact with FlowUs pages, databases, and blocks

119 lines (118 loc) 4.81 kB
"use strict"; /* tslint:disable */ /* eslint-disable */ /** * FlowUs API * FlowUs Developer API * * The version of the OpenAPI document: 1.0.0 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ Object.defineProperty(exports, "__esModule", { value: true }); exports.BlockDataBackgroundColorEnum = exports.BlockDataTextColorEnum = void 0; exports.instanceOfBlockData = instanceOfBlockData; exports.BlockDataFromJSON = BlockDataFromJSON; exports.BlockDataFromJSONTyped = BlockDataFromJSONTyped; exports.BlockDataToJSON = BlockDataToJSON; exports.BlockDataToJSONTyped = BlockDataToJSONTyped; const BlockDataExternal_1 = require("./BlockDataExternal"); const RichTextItem_1 = require("./RichTextItem"); const BlockDataFile_1 = require("./BlockDataFile"); const BlockDataSyncedFrom_1 = require("./BlockDataSyncedFrom"); const Icon_1 = require("./Icon"); /** * @export */ exports.BlockDataTextColorEnum = { Default: 'default', Gray: 'gray', Brown: 'brown', Orange: 'orange', Yellow: 'yellow', Green: 'green', Blue: 'blue', Purple: 'purple', Pink: 'pink', Red: 'red' }; /** * @export */ exports.BlockDataBackgroundColorEnum = { Default: 'default', Gray: 'gray', Brown: 'brown', Orange: 'orange', Yellow: 'yellow', Green: 'green', Blue: 'blue', Purple: 'purple', Pink: 'pink', Red: 'red' }; /** * Check if a given object implements the BlockData interface. */ function instanceOfBlockData(value) { return true; } function BlockDataFromJSON(json) { return BlockDataFromJSONTyped(json, false); } function BlockDataFromJSONTyped(json, ignoreDiscriminator) { if (json == null) { return json; } return { 'rich_text': json['rich_text'] == null ? undefined : (json['rich_text'].map(RichTextItem_1.RichTextItemFromJSON)), 'text_color': json['text_color'] == null ? undefined : json['text_color'], 'background_color': json['background_color'] == null ? undefined : json['background_color'], 'checked': json['checked'] == null ? undefined : json['checked'], 'language': json['language'] == null ? undefined : json['language'], 'url': json['url'] == null ? undefined : json['url'], 'caption': json['caption'] == null ? undefined : (json['caption'].map(RichTextItem_1.RichTextItemFromJSON)), 'icon': json['icon'] == null ? undefined : (0, Icon_1.IconFromJSON)(json['icon']), 'expression': json['expression'] == null ? undefined : json['expression'], 'page_id': json['page_id'] == null ? undefined : json['page_id'], 'table_width': json['table_width'] == null ? undefined : json['table_width'], 'has_column_header': json['has_column_header'] == null ? undefined : json['has_column_header'], 'has_row_header': json['has_row_header'] == null ? undefined : json['has_row_header'], 'cells': json['cells'] == null ? undefined : json['cells'], 'title': json['title'] == null ? undefined : json['title'], 'synced_from': json['synced_from'] == null ? undefined : (0, BlockDataSyncedFrom_1.BlockDataSyncedFromFromJSON)(json['synced_from']), 'file': json['file'] == null ? undefined : (0, BlockDataFile_1.BlockDataFileFromJSON)(json['file']), 'external': json['external'] == null ? undefined : (0, BlockDataExternal_1.BlockDataExternalFromJSON)(json['external']), }; } function BlockDataToJSON(json) { return BlockDataToJSONTyped(json, false); } function BlockDataToJSONTyped(value, ignoreDiscriminator = false) { if (value == null) { return value; } return { 'rich_text': value['rich_text'] == null ? undefined : (value['rich_text'].map(RichTextItem_1.RichTextItemToJSON)), 'text_color': value['text_color'], 'background_color': value['background_color'], 'checked': value['checked'], 'language': value['language'], 'url': value['url'], 'caption': value['caption'] == null ? undefined : (value['caption'].map(RichTextItem_1.RichTextItemToJSON)), 'icon': (0, Icon_1.IconToJSON)(value['icon']), 'expression': value['expression'], 'page_id': value['page_id'], 'table_width': value['table_width'], 'has_column_header': value['has_column_header'], 'has_row_header': value['has_row_header'], 'cells': value['cells'], 'title': value['title'], 'synced_from': (0, BlockDataSyncedFrom_1.BlockDataSyncedFromToJSON)(value['synced_from']), 'file': (0, BlockDataFile_1.BlockDataFileToJSON)(value['file']), 'external': (0, BlockDataExternal_1.BlockDataExternalToJSON)(value['external']), }; }