@silexlabs/silex 3.0.0-alpha.79 → 3.0.0-alpha.80

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,20 @@
1
1
  import { Asset, ClientSideFileType, ConnectorId, Page, Style, WebsiteId } from '../types';
2
+ /**
3
+ * Function to convert a path from it stored version to the displayed version
4
+ * Stored version is like `/assets/image.webp`
5
+ * Grapesjs version is like `/api/website/assets/image.webp?websiteId=47868975&connectorId=gitlab`
6
+ * Exported for unit tests
7
+ */
8
+ export declare function storedToDisplayed(path: string, websiteId: WebsiteId, storageId: ConnectorId): string;
9
+ /**
10
+ * Function to convert a path from the one we give to grapesjs to the stored version
11
+ * Grapesjs version is like `/api/website/assets/image.webp?websiteId=47868975&connectorId=gitlab`
12
+ * Stored version is like `/assets/image.webp`
13
+ * @param path the path to convert
14
+ * @returns the converted path
15
+ * Exported for unit tests
16
+ */
17
+ export declare function displayedToStored(path: string): string;
2
18
  /**
3
19
  * Publication transformer to convert the asset URL during publication
4
20
  */