Commit Graph
7 Commits
Author SHA1 Message Date
Bogdan Chadkin 59b6471c4f experimental: support paste html (#5185)
Ref https://github.com/webstudio-is/webstudio/issues/4404

Slightly reworked paste story. Now minimal API to insert html looks like
this

```js
const fragment = generateFragmentFromHtml(html);
insertWebstudioFragmentAt(fragment);
```

- attributes are casted to string, number and boolean types
- text is wrapped with spans when outside of rich text
- unsupported tags are ignored in result



https://github.com/user-attachments/assets/c8072d86-72bd-4446-a26a-e678b193f93e
2025-05-06 13:31:13 +04:00
Bogdan Chadkin 23034dad25 feat: add global system variable in builder (#4896)
Closes https://github.com/webstudio-is/webstudio/issues/4166

Now system is global variable and can be accessed in slots.

Legacy one can be deleted

<img width="264" alt="image"
src="https://github.com/user-attachments/assets/1c1d60f5-6be2-4871-9970-3593e3e7c08a"
/>
2025-02-23 01:46:21 +07:00
Bogdan Chadkin b7e1c86f68 experimental: generate global system variable with CLI (#4885)
Here added support for generating global system variable with CLI. It's
not available yet in builder though.

Global system not presented in data but instead can be referenced with
`$ws$system` in expression instead of encoded id like
`$ws$dataSource$id`. Legacy page system variable will continue to work.
2025-02-17 16:50:55 +07:00
Bogdan Chadkin 8ed3fbb085 feat: support global data variables (#4870)
Ref https://github.com/webstudio-is/webstudio/issues/4166
https://github.com/webstudio-is/webstudio/issues/3686

Added "Settings" section to global root. Now users can create data
variables which are available for all pages and inside slots.



https://github.com/user-attachments/assets/be2cf862-08ec-427e-aea3-076fa03a4437
2025-02-15 01:23:16 +08:00
Bogdan Chadkin ce475d4677 experimental: support copying root styles from marketplace (#4193)
Ref https://github.com/webstudio-is/webstudio/issues/3399

Now we have a way to deliver custom properties to user projects.
2024-10-02 15:06:14 +03:00
Bogdan Chadkin 59e1a87953 fix: append iterator to page when inserting from marketplace (#3433)
Fixes https://github.com/webstudio-is/webstudio/issues/3431

Here improved page name logic to check conflicts in target folder.
2024-05-28 01:44:03 +03:00
Bogdan Chadkin 9980bb9f47 refactor: generalize page copying logic (#3424)
Ref https://github.com/webstudio-is/webstudio/issues/3397

Here split insertPageCopyMutable from duplicatePage utility. It
basically can extract page from any data and insert into any data. I
will reuse it in marketplace later.

Also fixed copying status, redirect and language fields. Their variables
were not updated with new ids.
2024-05-26 20:11:43 +03:00