Simon Hausmann
9a8c5fed9f
Remove the ugly style
...
It's ugly ;-)
The combo box for the style is commented out for now, so that we can
easily re-add it in the future once we add a new style.
2022-04-13 10:35:42 +02:00
Tobias Hunger
4230ac2572
Update copyright information to reflect name change
...
Also run resue over the codebase and fix complaints from that tool.
2022-02-09 10:27:47 +01:00
Simon Hausmann
ab665b0007
Use new now SVG logo instead of the old SixtyFPS logo
...
In the online editor/preview as well as the doc preview.
2022-02-08 19:00:59 +01:00
Olivier Goffart
1425ef63de
Change the Url from sixtyfps.io to slint-ui.com
...
Also, change the URL of the logo in the docs
2022-02-08 08:52:46 +01:00
Olivier Goffart
00ff5e21a7
Update git repository URL
2022-02-08 08:26:21 +01:00
Olivier Goffart
79f35160b6
Fix typo in the online editor
2022-02-02 13:57:41 +01:00
Olivier Goffart
f4a824cf61
Rename the wasm-interpreter and the online_editor
2022-02-02 12:26:55 +01:00
Olivier Goffart
d706d63ce1
Replace references to the .60 files that are now renamed with .slint
2022-02-02 10:12:31 +01:00
Olivier Goffart
0308f86cd4
Rename sixtyfps_widgets.60 to std-widgets.slint
2022-02-01 18:58:54 +01:00
Simon Hausmann
bf865d4036
Further trim the dist build of the online editor
...
Re-use the wasm interpreter from the web site when building for the web
site. It's built & copied in the CI at the same time, and we can
convince rollup to preserve the relative link for production builds,
while aliasing to the local directory for dev builds.
This brings down the editor to ~2.3MB on my machine.
2022-01-06 09:55:34 +01:00
Simon Hausmann
8bd9e4ec8a
Trim the monaco-editor component in the online editor
...
Exclude ~7mb of language support for programming languages we don't need.
2022-01-06 09:55:34 +01:00
Simon Hausmann
0df394a389
Make it faster to develop the online editor
...
Switch from webpack to vite. The dev mode is practically instant.
2022-01-06 09:55:34 +01:00
Tobias Hunger
bfca0e3573
Mass update copyright messages to be more REUSE compliant
2021-12-22 10:06:12 +01:00
Tobias Hunger
aea4ecca99
Apply pre-commit hooks to all files
2021-08-17 22:38:16 +02:00
Olivier Goffart
23e3c68357
Online editor: ability to select the style
2021-08-07 12:49:53 +02:00
Olivier Goffart
13bd828b96
Update license date
2021-07-02 15:55:54 +02:00
Olivier Goffart
d51ea1429d
Online editor: check the url to load from a branch
2021-07-01 09:42:25 +02:00
Simon Hausmann
ef1a605953
Add support for showing warning diagnostics in the online editor
2021-04-30 15:43:05 +02:00
Simon Hausmann
36cbe0b342
Fix build
...
Amends commit afe3df6381
These functions were removed and need to be re-added in a different way in the interpreter for async
loading/embedding later
2021-04-14 11:01:43 +02:00
Simon Hausmann
3391aa0312
Remove the import resolve callback from the compiler configuration
...
Re-apply commit 2dcbc45cd6
but now do the
resolution from a relative import path to either an absolute path or url
in the compiler itself.
2021-03-16 14:21:33 +01:00
Simon Hausmann
e3a33dffe0
Revert "Remove the import resolve callback from the compiler configuration"
...
This reverts commit 2dcbc45cd6
.
It breaks loading of the printer demo in the editor because in
import_file we fail to return the absolute path and thus end up
importing common.60 too many times.
2021-03-16 11:43:33 +01:00
Simon Hausmann
2dcbc45cd6
Remove the import resolve callback from the compiler configuration
...
It turns out that this isn't really needed with the current
implementation.
2021-03-15 20:02:46 +01:00
Simon Hausmann
f30cb7f4d8
Add support for font_url
params to the online editor and previewer
2021-02-17 15:28:18 +01:00
Olivier Goffart
23a511b380
Replace img!"..."
by @image-url("...")
2021-01-28 11:49:24 +01:00
Simon Hausmann
0788a33c9a
Fix online editor transition from errors to error free source
...
Markers are show inline when errors occur during compilation. But when
those errors are fixed, the markers should go away.
2020-12-07 15:02:14 +01:00
Simon Hausmann
8c477998dc
Load the logo in the examples off the website
...
This will allow moving them out of the repo and also makes the urls shorter.
2020-11-25 09:34:47 +01:00
Simon Hausmann
fb2f4d7508
Speed up the online editor loading
...
Split the monaco editor out into a separate JS bundle, which we can load in parallel with the wasm interpreter.
Previously we'd load a 2.x mb app.bundle.js and *then* the wasm interpreter.
2020-11-11 12:21:57 +01:00
Simon Hausmann
6a1cd307ff
Another small tweak to the hello world
...
Since this will be the first thing many people see, add a small comment inline about
logical pixels.
2020-11-09 10:24:10 +01:00
Simon Hausmann
dff5d8ab25
Minor tweak to the hello world in the online editor
...
Make the text slightly more readable by increasing the font size and showing
off css-style identifiers at the same time.
2020-11-09 10:21:02 +01:00
Olivier Goffart
c3ba10fa90
Syntax highlighting also in the secondary tabs
2020-11-03 19:38:08 +01:00
Olivier Goffart
21d2acf84c
Allow to import URL even if base_url is empty
2020-11-03 19:36:10 +01:00
Olivier Goffart
2ebc9d23fb
Fix syntax highlighting in the online editor
2020-11-03 12:42:07 +01:00
Simon Hausmann
fa077662c1
Remove stray debug output
2020-11-03 10:14:56 +01:00
Simon Hausmann
e3880d6aff
Save and restore view state when switching between tabs in the online editor
2020-11-03 10:14:11 +01:00
Simon Hausmann
7c4338a673
Fix typo and missing type annotations
2020-11-03 10:07:19 +01:00
Simon Hausmann
dc87898ca0
Support automatic compilation for all tabs in the online editor
2020-11-03 10:05:58 +01:00
Simon Hausmann
e0fd1259b3
Add support for viewing the contents of other tabs in the online editor
2020-11-03 10:02:11 +01:00
Simon Hausmann
47c99df775
Rework the tab model in the online editor
...
Store monaco editor models instead of the source code.
2020-11-03 09:52:18 +01:00
Simon Hausmann
2028723eee
online-editor: create tabs for each loaded document
2020-11-02 20:01:06 +01:00
Simon Hausmann
d435a7c8b8
Fix loading of images from imported files in the online editor
...
We need to separate the url resolution step from the document fetching,
as we need to keep the loaded url in Rust for further
resolution.
2020-11-02 14:57:49 +01:00
Simon Hausmann
330f61d6c1
Add support for loading external files in the wasm interpreter
...
The imported files don't have tabs though, and caching is done entirely
by the browser.
2020-11-02 13:46:58 +01:00
Simon Hausmann
69029e2e49
Online editor tweak
...
Use a tab bar and show at least one tab with the main source file name
Also use bootstrap for the styling
2020-10-30 16:35:04 +01:00
Olivier Goffart
359f42c5f7
Prepare the compiler to be async
...
This will allow the online editor to load imports from URL asynchroniously later
Since currently the compiler is only working on a single thread, and that we
never await on a future that could block, it is allowed to use the spin_on executor
2020-10-30 15:00:04 +01:00
Simon Hausmann
6aa292eac1
Change the names of the logical and physical pixel units
...
The logical pixels are now just called "px" and the less frequently
used physical pixels have the "phx" suffix.
The existing markup was adapted using the syntax updater and the
following patch:
+ if node.kind() == SyntaxKind::NumberLiteral {
+ if node.text().ends_with("lx") {
+ return write!(
+ file,
+ "{}px",
+ node.text().as_str().split_at(node.text().as_str().len() - 2).0
+ );
+ }
+ if node.text().ends_with("px") {
+ return write!(
+ file,
+ "{}phx",
+ node.text().as_str().split_at(node.text().as_str().len() - 2).0
+ );
+ }
+ }
Fixes #49
2020-10-16 07:19:40 +02:00
Olivier Goffart
cbf252f73b
Online editor: go back to hello world if no demo is selected
2020-10-12 12:25:34 +02:00
Olivier Goffart
0845b4ab85
Online editor: Add a timeout
2020-10-12 12:22:49 +02:00
Olivier Goffart
69b07eee53
Revert the changes to the hello world in the code editor
...
These were not meant to be commited
2020-10-10 15:46:38 +02:00
Olivier Goffart
8ec820cb9f
Online editor syntax highliting
2020-10-10 13:00:14 +02:00
Olivier Goffart
29f4910cbd
Some changes to the online editor
...
- Set a small hello world by default
- add a permalink
- allow to load an URL
2020-10-09 13:14:30 +02:00
Simon Hausmann
67f387e628
Prepare for relative resource loading from the web
...
Pass the base url as path to the interpreter
2020-10-08 20:42:46 +02:00