diff --git a/container/typings/LuigiContainer.svelte.d.ts b/container/typings/LuigiContainer.svelte.d.ts index ecddd28142..091254814c 100644 --- a/container/typings/LuigiContainer.svelte.d.ts +++ b/container/typings/LuigiContainer.svelte.d.ts @@ -122,6 +122,8 @@ export default class LuigiContainer extends HTMLElement { /** * The list of rules for the content in the iframe, managed by the HTML `allow` attribute. * You can use one or more rules by adding them to the array, for example allowRules: ["microphone", "camera"]. + * @example + * @example containerElement.allowRules = ['microphone', 'camera'] * @since 1.2.0 */ allowRules: string[]; @@ -129,6 +131,8 @@ export default class LuigiContainer extends HTMLElement { /** * The list of rules for the content in the iframe, managed by the HTML `sandbox` attribute. * You can use one or more rules by adding them to the array, for example sandboxRules: ["allow-scripts", "allow-same-origin"]. + * @example + * @example containerElement.sandboxRules = ['allow-modals', 'allow-popups'] * @since 1.2.0 */ sandboxRules: string[]; diff --git a/docs/luigi-container-api.md b/docs/luigi-container-api.md index 09fa2b98ba..b3d52fcf2b 100644 --- a/docs/luigi-container-api.md +++ b/docs/luigi-container-api.md @@ -208,6 +208,16 @@ You can use one or more rules by adding them to the array, for example allowRule Type: [Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)<[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)> +#### Examples + +```javascript + +``` + +```javascript +containerElement.allowRules = ['microphone', 'camera'] +``` + **Meta** * **since**: 1.2.0 @@ -219,6 +229,16 @@ You can use one or more rules by adding them to the array, for example sandboxRu Type: [Array](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/Array)<[string](https://developer.mozilla.org/docs/Web/JavaScript/Reference/Global_Objects/String)> +#### Examples + +```javascript + +``` + +```javascript +containerElement.sandboxRules = ['allow-modals', 'allow-popups'] +``` + **Meta** * **since**: 1.2.0