@acoustic-content-sdk/react-edit-api 中文文档教程

发布于 4年前 浏览 14 更新于 3年前

npm

编辑模式下 React SDK 的 API 和常量集合。

Table of Contents

首页首页 @acoustic-content-sdk/react-edit-api

react-edit-api package

编辑模式下 React SDK 的 API 和常量集合。

Functions

FunctionDescription
selectDebugPlaceholder(aConfig)
selectDefaultPlaceholder(aConfig)
selectInlineEditURL(aConfig)
selectPlaceholderTag(aConfig)
selectThrottleLoading(aConfig)

Interfaces

InterfaceDescription
EditHubInfoService
WchPlaceholder
WchPlaceholderProvider

Variables

VariableDescription
ACOUSTIC_CONTEXT_ACOUSTIC_CONFIGInjection token for the wch config
ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERSInjection token for placeholder debugging
ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXTInjection token for default placeholder text
ACOUSTIC_CONTEXT_EDIT_HOST_WINDOWInjects the window that acts as the edit host for an application. This is typically the parent window or the opener window.
ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDERInjection token for the inline edit provider
ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDERProvides information about the inline edit selection
ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE
ACOUSTIC_CONTEXT_INLINE_EDIT_URL
ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER
DEFAULT_DEBUG_PLACEHOLDERSper default do not debug
DEFAULT_INLINE_EDIT_URLdefault value for the inline edit URL
EVENT_EDIT_END
EVENT_EDIT_START
EVENT_INLINE_EDIT_END
EVENT_INLINE_EDIT_START
VERSIONVersion and build number of the package

Type Aliases

Type AliasDescription
WchDefaultPlaceholdertype for placeholder

Home > @acoustic-content-sdk/react-edit-api > selectDebugPlaceholder

selectDebugPlaceholder() function

Signature:

export declare function selectDebugPlaceholder(aConfig?: EditHubInfoService): boolean;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

boolean

主页 > @acoustic-content-sdk/react-edit-api > selectDefaultPlaceholder

selectDefaultPlaceholder() function

Signature:

export declare function selectDefaultPlaceholder(aConfig?: EditHubInfoService): WchDefaultPlaceholder;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

WchDefaultPlaceholder

主页 > @acoustic-content-sdk/react-edit-api > selectInlineEditURL

selectInlineEditURL() function

Signature:

export declare function selectInlineEditURL(aConfig?: EditHubInfoService): HubInfoUrlProvider;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

HubInfoUrlProvider

主页 > @acoustic-content-sdk/react-edit-api > selectPlaceholderTag

selectPlaceholderTag() function

Signature:

export declare function selectPlaceholderTag(aConfig?: EditHubInfoService): string;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

string

主页 > @acoustic-content-sdk/react-edit-api > selectThrottleLoading

selectThrottleLoading() function

Signature:

export declare function selectThrottleLoading(aConfig?: EditHubInfoService): number;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

number

主页 > @acoustic-content-sdk/react-edit-api > EditHubInfoService

EditHubInfoService interface

Signature:

export interface EditHubInfoService 

Properties

PropertyTypeDescription
debugPlaceholdersbooleanEnable or disable placeholders even if inline edit mode has not been enabled
defaultPlaceholderTextWchDefaultPlaceholderProvide a default placeholder text
inlineEditUrlHubInfoUrlProvider
placeholderTagstringTag used to find placeholder content items. If left undefined, placeholders will not be inserted, automatically
throttleLoadingnumberThrottle loading of lib

Home > ; @acoustic-content-sdk/react-edit-api > WchPlaceholder

WchPlaceholder interface

Signature:

export interface WchPlaceholder 

Properties

PropertyTypeDescription
accessor$Observable<string>The accessor expression
data$Observable<any>Generates the accessed data, decoded from the accessor expression
formattedText$Observable<LocalizedText>Generates the formatted text of an element, potentially replaced by the placeholder
placeholder$Observable<AuthoringPlaceholder>Event exposing the current placeholder. If no placeholder exists or placeholders are disabled, this will return 'undefined'.
placeholderText$Observable<LocalizedText>Event exposing the current placeholder text. If placeholders are disabled, this will return 'undefined'. If no placeholder has been defined this returns the default placeholder as specified by the application, else 'undefined'.
plainText$Observable<LocalizedText>Generates the text of an element, potentially replaced by the placeholder
showPlaceholder$Observable<boolean>Checks if we should show or hide placeholders
typeId$Observable<string>Decodes the type of the currently accessed element

Home > ; @acoustic-content-sdk/react-edit-api > WchPlaceholderProvider

WchPlaceholderProvider interface

Signature:

export interface WchPlaceholderProvider 

Properties

PropertyTypeDescription
getPlaceholder(aAccessor: AccessorType, aProvider: RenderingContextProviderV2) => WchPlaceholder

Home > ; @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_ACOUSTIC_CONFIG

ACOUSTIC_CONTEXT_ACOUSTIC_CONFIG variable

Injection token for the wch config

Signature:

ACOUSTIC_CONTEXT_ACOUSTIC_CONFIG: Required<import("react").Context<Observable<WchConfig>>>

首页 > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERS

ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERS variable

Injection token for placeholder debugging

Signature:

ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERS: Required<import("react").Context<boolean>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXT

ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXT variable

Injection token for default placeholder text

Signature:

ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXT: Required<import("react").Context<import("@acoustic-content-sdk/utils").ObservableOrT<string | import("@acoustic-content-sdk/api").LocalizedText>>>

首页 > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_EDIT_HOST_WINDOW

ACOUSTIC_CONTEXT_EDIT_HOST_WINDOW variable

注入充当应用程序编辑主机的窗口。 这通常是父窗口或开启者窗口。

Signature:

ACOUSTIC_CONTEXT_EDIT_HOST_WINDOW: Required<import("react").Context<WindowType>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDER

ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDER variable

Injection token for the inline edit provider

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDER: Required<import("react").Context<Observable<WchInlineEditProviderV2>>>

首页 > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDER

ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDER variable

Provides information about the inline edit selection

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDER: Required<import("react").Context<InlineEditSelectionProvider>>

首页 > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE

ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE variable

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE: Required<import("react").Context<WchInlineEditServiceV2>>

Home > ; @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_URL

ACOUSTIC_CONTEXT_INLINE_EDIT_URL variable

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_URL: Required<import("react").Context<StaticHubInfoUrlProvider>>

Home > ; @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER

ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER variable

Signature:

ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER: Required<import("react").Context<WchPlaceholderProvider>>

Home > ; @acoustic-content-sdk/react-edit-api > DEFAULT_DEBUG_PLACEHOLDERS

DEFAULT_DEBUG_PLACEHOLDERS variable

per default do not debug

Signature:

DEFAULT_DEBUG_PLACEHOLDERS = false

Home > @acoustic-content-sdk/react-edit-api > DEFAULT_INLINE_EDIT_URL

DEFAULT_INLINE_EDIT_URL variable

default value for the inline edit URL

Signature:

DEFAULT_INLINE_EDIT_URL = "${authoringUIBaseUrl.protocol}//${authoringUIBaseUrl.host}/authoring-sites-ui/inline-edit/inline-edit.js"

首页 > @acoustic-content-sdk/react-edit-api > EVENT_EDIT_END

EVENT_EDIT_END variable

Signature:

EVENT_EDIT_END = "wchEditEnd"

Home > ; @acoustic-content-sdk/react-edit-api > EVENT_EDIT_START

EVENT_EDIT_START variable

Signature:

EVENT_EDIT_START = "wchEditStart"

Home > ; @acoustic-content-sdk/react-edit-api > EVENT_INLINE_EDIT_END

EVENT_INLINE_EDIT_END variable

Signature:

EVENT_INLINE_EDIT_END = "wchInlineEditEnd"

Home > ; @acoustic-content-sdk/react-edit-api > EVENT_INLINE_EDIT_START

EVENT_INLINE_EDIT_START variable

Signature:

EVENT_INLINE_EDIT_START = "wchInlineEditStart"

Home > ; @acoustic-content-sdk/react-edit-api > VERSION

VERSION variable

Version and build number of the package

Signature:

VERSION: {
    version: {
        major: string;
        minor: string;
        patch: string;
        branch: string;
    };
    build: Date;
}

首页 > @acoustic-content-sdk/react-edit-api > WchDefaultPlaceholder

WchDefaultPlaceholder type

type for placeholder

Signature:

export declare type WchDefaultPlaceholder = ObservableOrT<string | LocalizedText>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > accessor$

WchPlaceholder.accessor$ property

The accessor expression

Signature:

accessor$: Observable<string>;

Home< /a> > @acoustic-content-sdk/react-edit-api > WchPlaceholder > data$

WchPlaceholder.data$ property

Generates the accessed data, decoded from the accessor expression

Signature:

data$: Observable<any>;

主页 > @acoustic-content-sdk/react-edit-api > WchPlaceholder > formattedText$

WchPlaceholder.formattedText$ property

Generates the formatted text of an element, potentially replaced by the placeholder

Signature:

formattedText$: Observable<LocalizedText>;

< a href="#_ebb4e1bd9a98cff53874e421af3f2a0c06a8a0b653399b8441e18d5076aa7260">主页 > @acoustic-content-sdk/react-edit-api > WchPlaceholder > placeholder$

WchPlaceholder.placeholder$ property

暴露当前占位符的事件。 如果不存在占位符或占位符被禁用,这将返回“未定义”。

Signature:

placeholder$: Observable<AuthoringPlaceholder>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > placeholderText$

WchPlaceholder.placeholderText$ property

暴露当前占位符文本的事件。 如果占位符被禁用,这将返回“未定义”。 如果未定义占位符,则返回应用程序指定的默认占位符,否则为“未定义”。

Signature:

placeholderText$: Observable<LocalizedText>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > plainText$

WchPlaceholder.plainText$ property

Generates the text of an element, potentially replaced by the placeholder

Signature:

plainText$: Observable<LocalizedText>;

主页 > @acoustic-content-sdk/react-edit-api > WchPlaceholder > showPlaceholder$

WchPlaceholder.showPlaceholder$ property

Checks if we should show or hide placeholders

Signature:

showPlaceholder$: Observable<boolean>;

主页 > @acoustic-content-sdk/react-edit-api > WchPlaceholder > typeId$ Decodes

WchPlaceholder.typeId$ property

the type of the currently accessed element

Signature:

typeId$: Observable<string>;

主页 > @acoustic-content-sdk/react-edit-api > WchPlaceholderProvider > getPlaceholder

WchPlaceholderProvider.getPlaceholder property

Signature:

getPlaceholder: (aAccessor: AccessorType, aProvider: RenderingContextProviderV2) => WchPlaceholder;

Home > ; @acoustic-content-sdk/react-edit-api > EditHubInfoService > debugPlaceholders

EditHubInfoService.debugPlaceholders property

Enable or disable placeholders even if inline edit mode has not been enabled

Signature:

readonly debugPlaceholders?: boolean;

主页 > @acoustic-content-sdk/react-edit-api > EditHubInfoService > defaultPlaceholderText

EditHubInfoService.defaultPlaceholderText property

Provide a default placeholder text

Signature:

readonly defaultPlaceholderText?: WchDefaultPlaceholder;

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService > inlineEditUrl

EditHubInfoService.inlineEditUrl property

Signature:

readonly inlineEditUrl?: HubInfoUrlProvider;

Home > ; @acoustic-content-sdk/react-edit-api > EditHubInfoService > placeholderTag

EditHubInfoService.placeholderTag property

用于查找占位符内容项的标签。 If left undefined, placeholders will not be inserted, automatically

Signature:

readonly placeholderTag?: string;

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService > throttleLoading

EditHubInfoService.throttleLoading property

节流加载 lib

签名:

readonly throttleLoading?: number;

npm

Collection of APIs and constants for the React SDK in edit mode.

Table of Contents

Home > @acoustic-content-sdk/react-edit-api

react-edit-api package

Collection of APIs and constants for the React SDK in edit mode.

Functions

FunctionDescription
selectDebugPlaceholder(aConfig)
selectDefaultPlaceholder(aConfig)
selectInlineEditURL(aConfig)
selectPlaceholderTag(aConfig)
selectThrottleLoading(aConfig)

Interfaces

InterfaceDescription
EditHubInfoService
WchPlaceholder
WchPlaceholderProvider

Variables

VariableDescription
ACOUSTIC_CONTEXT_ACOUSTIC_CONFIGInjection token for the wch config
ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERSInjection token for placeholder debugging
ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXTInjection token for default placeholder text
ACOUSTIC_CONTEXT_EDIT_HOST_WINDOWInjects the window that acts as the edit host for an application. This is typically the parent window or the opener window.
ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDERInjection token for the inline edit provider
ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDERProvides information about the inline edit selection
ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE
ACOUSTIC_CONTEXT_INLINE_EDIT_URL
ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER
DEFAULT_DEBUG_PLACEHOLDERSper default do not debug
DEFAULT_INLINE_EDIT_URLdefault value for the inline edit URL
EVENT_EDIT_END
EVENT_EDIT_START
EVENT_INLINE_EDIT_END
EVENT_INLINE_EDIT_START
VERSIONVersion and build number of the package

Type Aliases

Type AliasDescription
WchDefaultPlaceholdertype for placeholder

Home > @acoustic-content-sdk/react-edit-api > selectDebugPlaceholder

selectDebugPlaceholder() function

Signature:

export declare function selectDebugPlaceholder(aConfig?: EditHubInfoService): boolean;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

boolean

Home > @acoustic-content-sdk/react-edit-api > selectDefaultPlaceholder

selectDefaultPlaceholder() function

Signature:

export declare function selectDefaultPlaceholder(aConfig?: EditHubInfoService): WchDefaultPlaceholder;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

WchDefaultPlaceholder

Home > @acoustic-content-sdk/react-edit-api > selectInlineEditURL

selectInlineEditURL() function

Signature:

export declare function selectInlineEditURL(aConfig?: EditHubInfoService): HubInfoUrlProvider;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

HubInfoUrlProvider

Home > @acoustic-content-sdk/react-edit-api > selectPlaceholderTag

selectPlaceholderTag() function

Signature:

export declare function selectPlaceholderTag(aConfig?: EditHubInfoService): string;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

string

Home > @acoustic-content-sdk/react-edit-api > selectThrottleLoading

selectThrottleLoading() function

Signature:

export declare function selectThrottleLoading(aConfig?: EditHubInfoService): number;

Parameters

ParameterTypeDescription
aConfigEditHubInfoService

Returns:

number

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService

EditHubInfoService interface

Signature:

export interface EditHubInfoService 

Properties

PropertyTypeDescription
debugPlaceholdersbooleanEnable or disable placeholders even if inline edit mode has not been enabled
defaultPlaceholderTextWchDefaultPlaceholderProvide a default placeholder text
inlineEditUrlHubInfoUrlProvider
placeholderTagstringTag used to find placeholder content items. If left undefined, placeholders will not be inserted, automatically
throttleLoadingnumberThrottle loading of lib

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder

WchPlaceholder interface

Signature:

export interface WchPlaceholder 

Properties

PropertyTypeDescription
accessor$Observable&lt;string&gt;The accessor expression
data$Observable&lt;any&gt;Generates the accessed data, decoded from the accessor expression
formattedText$Observable&lt;LocalizedText&gt;Generates the formatted text of an element, potentially replaced by the placeholder
placeholder$Observable&lt;AuthoringPlaceholder&gt;Event exposing the current placeholder. If no placeholder exists or placeholders are disabled, this will return 'undefined'.
placeholderText$Observable&lt;LocalizedText&gt;Event exposing the current placeholder text. If placeholders are disabled, this will return 'undefined'. If no placeholder has been defined this returns the default placeholder as specified by the application, else 'undefined'.
plainText$Observable&lt;LocalizedText&gt;Generates the text of an element, potentially replaced by the placeholder
showPlaceholder$Observable&lt;boolean&gt;Checks if we should show or hide placeholders
typeId$Observable&lt;string&gt;Decodes the type of the currently accessed element

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholderProvider

WchPlaceholderProvider interface

Signature:

export interface WchPlaceholderProvider 

Properties

PropertyTypeDescription
getPlaceholder(aAccessor: AccessorType, aProvider: RenderingContextProviderV2) =&gt; WchPlaceholder

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_ACOUSTIC_CONFIG

ACOUSTIC_CONTEXT_ACOUSTIC_CONFIG variable

Injection token for the wch config

Signature:

ACOUSTIC_CONTEXT_ACOUSTIC_CONFIG: Required<import("react").Context<Observable<WchConfig>>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERS

ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERS variable

Injection token for placeholder debugging

Signature:

ACOUSTIC_CONTEXT_DEBUG_PLACEHOLDERS: Required<import("react").Context<boolean>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXT

ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXT variable

Injection token for default placeholder text

Signature:

ACOUSTIC_CONTEXT_DEFAULT_PLACEHOLDER_TEXT: Required<import("react").Context<import("@acoustic-content-sdk/utils").ObservableOrT<string | import("@acoustic-content-sdk/api").LocalizedText>>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_EDIT_HOST_WINDOW

ACOUSTIC_CONTEXT_EDIT_HOST_WINDOW variable

Injects the window that acts as the edit host for an application. This is typically the parent window or the opener window.

Signature:

ACOUSTIC_CONTEXT_EDIT_HOST_WINDOW: Required<import("react").Context<WindowType>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDER

ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDER variable

Injection token for the inline edit provider

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_PROVIDER: Required<import("react").Context<Observable<WchInlineEditProviderV2>>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDER

ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDER variable

Provides information about the inline edit selection

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_SELECTION_PROVIDER: Required<import("react").Context<InlineEditSelectionProvider>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE

ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE variable

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_SERVICE: Required<import("react").Context<WchInlineEditServiceV2>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_INLINE_EDIT_URL

ACOUSTIC_CONTEXT_INLINE_EDIT_URL variable

Signature:

ACOUSTIC_CONTEXT_INLINE_EDIT_URL: Required<import("react").Context<StaticHubInfoUrlProvider>>

Home > @acoustic-content-sdk/react-edit-api > ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER

ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER variable

Signature:

ACOUSTIC_CONTEXT_PLACEHOLDER_PROVIDER: Required<import("react").Context<WchPlaceholderProvider>>

Home > @acoustic-content-sdk/react-edit-api > DEFAULT_DEBUG_PLACEHOLDERS

DEFAULT_DEBUG_PLACEHOLDERS variable

per default do not debug

Signature:

DEFAULT_DEBUG_PLACEHOLDERS = false

Home > @acoustic-content-sdk/react-edit-api > DEFAULT_INLINE_EDIT_URL

DEFAULT_INLINE_EDIT_URL variable

default value for the inline edit URL

Signature:

DEFAULT_INLINE_EDIT_URL = "${authoringUIBaseUrl.protocol}//${authoringUIBaseUrl.host}/authoring-sites-ui/inline-edit/inline-edit.js"

Home > @acoustic-content-sdk/react-edit-api > EVENT_EDIT_END

EVENT_EDIT_END variable

Signature:

EVENT_EDIT_END = "wchEditEnd"

Home > @acoustic-content-sdk/react-edit-api > EVENT_EDIT_START

EVENT_EDIT_START variable

Signature:

EVENT_EDIT_START = "wchEditStart"

Home > @acoustic-content-sdk/react-edit-api > EVENT_INLINE_EDIT_END

EVENT_INLINE_EDIT_END variable

Signature:

EVENT_INLINE_EDIT_END = "wchInlineEditEnd"

Home > @acoustic-content-sdk/react-edit-api > EVENT_INLINE_EDIT_START

EVENT_INLINE_EDIT_START variable

Signature:

EVENT_INLINE_EDIT_START = "wchInlineEditStart"

Home > @acoustic-content-sdk/react-edit-api > VERSION

VERSION variable

Version and build number of the package

Signature:

VERSION: {
    version: {
        major: string;
        minor: string;
        patch: string;
        branch: string;
    };
    build: Date;
}

Home > @acoustic-content-sdk/react-edit-api > WchDefaultPlaceholder

WchDefaultPlaceholder type

type for placeholder

Signature:

export declare type WchDefaultPlaceholder = ObservableOrT<string | LocalizedText>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > accessor$

WchPlaceholder.accessor$ property

The accessor expression

Signature:

accessor$: Observable<string>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > data$

WchPlaceholder.data$ property

Generates the accessed data, decoded from the accessor expression

Signature:

data$: Observable<any>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > formattedText$

WchPlaceholder.formattedText$ property

Generates the formatted text of an element, potentially replaced by the placeholder

Signature:

formattedText$: Observable<LocalizedText>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > placeholder$

WchPlaceholder.placeholder$ property

Event exposing the current placeholder. If no placeholder exists or placeholders are disabled, this will return 'undefined'.

Signature:

placeholder$: Observable<AuthoringPlaceholder>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > placeholderText$

WchPlaceholder.placeholderText$ property

Event exposing the current placeholder text. If placeholders are disabled, this will return 'undefined'. If no placeholder has been defined this returns the default placeholder as specified by the application, else 'undefined'.

Signature:

placeholderText$: Observable<LocalizedText>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > plainText$

WchPlaceholder.plainText$ property

Generates the text of an element, potentially replaced by the placeholder

Signature:

plainText$: Observable<LocalizedText>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > showPlaceholder$

WchPlaceholder.showPlaceholder$ property

Checks if we should show or hide placeholders

Signature:

showPlaceholder$: Observable<boolean>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholder > typeId$

WchPlaceholder.typeId$ property

Decodes the type of the currently accessed element

Signature:

typeId$: Observable<string>;

Home > @acoustic-content-sdk/react-edit-api > WchPlaceholderProvider > getPlaceholder

WchPlaceholderProvider.getPlaceholder property

Signature:

getPlaceholder: (aAccessor: AccessorType, aProvider: RenderingContextProviderV2) => WchPlaceholder;

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService > debugPlaceholders

EditHubInfoService.debugPlaceholders property

Enable or disable placeholders even if inline edit mode has not been enabled

Signature:

readonly debugPlaceholders?: boolean;

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService > defaultPlaceholderText

EditHubInfoService.defaultPlaceholderText property

Provide a default placeholder text

Signature:

readonly defaultPlaceholderText?: WchDefaultPlaceholder;

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService > inlineEditUrl

EditHubInfoService.inlineEditUrl property

Signature:

readonly inlineEditUrl?: HubInfoUrlProvider;

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService > placeholderTag

EditHubInfoService.placeholderTag property

Tag used to find placeholder content items. If left undefined, placeholders will not be inserted, automatically

Signature:

readonly placeholderTag?: string;

Home > @acoustic-content-sdk/react-edit-api > EditHubInfoService > throttleLoading

EditHubInfoService.throttleLoading property

Throttle loading of lib

Signature:

readonly throttleLoading?: number;
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文