Commit Graph
1607 Commits
Author SHA1 Message Date
RabsRincon ea25a2a3db Overly defensive fix for COMPILER-EXPLORER-5QF
It was caused by COMPILER-EXPLORER-5W1 as far as I can tell,
 but double-fixing it does not hurt
2020-01-08 10:59:22 +01:00
RabsRincon f1ebd12802 Fix linter checks by ignoring max line count
Only affects Compiler. Turns out, it needs to do its fair share of
things
2020-01-08 10:47:19 +01:00
RabsRincon 3a19e2297b Fixes Sentry issue COMPILER-EXPLORER-58F 2020-01-08 10:34:58 +01:00
Matt Godbolt 8c8452a223 January thanks 2020-01-06 21:43:22 -06:00
Ray Imber 0a68503d9c Fix linter errors. 2020-01-02 14:44:48 -08:00
Ray Imber a255a4a861 Added Monaco editor syntax highlight support for Nim. 2020-01-02 13:31:49 -08:00
Rubén Rincón Blanco 8f2829221c Merge pull request #1753 from DaemonSnake/master
Add support for Nim language
2020-01-01 15:38:48 +01:00
Patrick Quist 6648d56f55 History (localstorage) (#1735)
* add history to localstorage + way to restore state

* lintfixes

* work in progress; diffing of history

* lintfix

* inline diff

* set editor layout

* lintfix

* refactoring

* able to load from history from loadsave dialog

* different menu icon

* capitalisation consistency

* remove id's, dont seem to be needed

* maxHistoryEntries const

* refactor

* use class instead of id for inlinediff checkbox

* lintfix
2019-12-31 13:42:46 +01:00
bastien penavayre 3492287638 Add support for Nim language
- Add language
- Adds Nim compiler
- supports js, c, c++ outputs (objc not tested)
- prevent --run option
- Basic test for nim

Todos:
- monaco profile for Nim
2019-12-26 11:03:20 +01:00
RabsRincon 5924fd3bc7 Add option to keep current source on lang change
Closes #1604
2019-12-24 12:33:32 +01:00
Rubén Rincón 56968947d5 Fix compiler id duplication on cloning 2019-12-17 22:11:37 +01:00
RabsRincon 35b01d3e4e Make lineNumbers margins smaller
Closes #1726
2019-12-17 11:38:41 +01:00
Rubén Rincón Blanco a1daf61327 Merge pull request #1721 from porglezomp-misc/fix/some-dark-mode-icons
Fix the contrast on some dark-mode icons
2019-12-13 14:44:11 +01:00
Rubén Rincón Blanco 57bc279d7e Merge pull request #1722 from porglezomp-misc/feature/mobile-tab-tap-targets
Make tab view tabs larger on mobile
2019-12-13 14:42:57 +01:00
Cassie Jones d67d7a7c02 Fix dark-mode save/load UI
The save/load builds a tabbed list using a .active class to select which
tab to show. This class is also used for styling button highlights in
pickers. We can remove the bare .active and .active:hover rules because
they exactly match the .btn-light.active rules, and every other use of
the active class also has a btn-light class attached to it.

Fixes #1718
2019-12-10 03:22:49 -05:00
Cassie Jones 94fa092996 Make tab view tabs larger on mobile
This increases the size of the tab bar tabs and buttons on mobile, to
make it easier to work entirely in tab mode. The media query for this
button size begins at 768px because that's where the top bar UI switches
to mobile mode.

Fixes #1717
2019-12-10 02:55:39 -05:00
Cassie Jones 882e06258a Fix the contrast on some dark-mode icons
This adds some overrides for the hamburger menu styles in dark-mode, as
well as some low-specificity rules for the `fa` icons. They need to be
low specificity in order to avoid overriding colors for icons that are
specifically colored, like the green and red checks and Xs in the status
bars.

Fixes #1720
2019-12-10 02:11:50 -05:00
Matt Godbolt 8c086301c6 Merge pull request #1699 from csordasmarton/jmp_to_labels
Jump to labels in assembly
2019-12-09 21:13:27 -06:00
Rubén Rincón af6889f1f7 Fix compilers forgetting their proper id
Closes #1713

Special thanks to @lunasorcery for the detailed repro steps :)
2019-12-08 23:50:02 +01:00
Cassie Jones 3666acab8b Ensure the tab dropdown shows in front
When there are enough tabs, you use a dropdown selection to pick the
other tabs. This would display under the compiler selection dropdown
list, making it very difficult to use.

The .lm_tab dropdown has its z-index set to 5 to show up on top, but
it's stuck inside the .lm_header stacking context, so it can't render
in front of that. Raising the z-index of that whole stacking context
fixes things.

Fixes #1714
2019-12-07 17:51:27 -05:00
Márton Csordás 6f6c0dbeb2 Fix review comments of the Jump to label feature
- Use `const` where it is possible.
- Move regexes into variables and give them a name.
- Eliminate `lineNumber` variable and use the length of the asm array.
- Use `updateDecorations()` function to decorate label usages.
- Update and fix test cases.
2019-12-04 20:56:21 +01:00
Matt Godbolt f1ee4abdee Ondra's legendary support is in memoriam Jaroslav Křivánek. 2019-12-04 09:31:06 -06:00
Matt Godbolt c034895e2f ...and of course @sthagen was already an amazing LEGENDARY supporter! *blush* :) 2019-12-02 20:35:29 -06:00
Matt Godbolt 297e894c1f Thanks to our first GH legendary supporter, @sthagen 2019-12-02 20:33:47 -06:00
Matt Godbolt c728e2291e December thanks 2019-12-02 07:24:22 -06:00
Márton Csordás c1d074d6d5 Parse assembly labels on the serve-side
Parsing the labels on the server-side is more general, more flexible
and it can be easily tested.

- Store label definitions in a map. The key will be the label name and
the value will be the line number where the label definition can be
found.
- For each line get the labels which are used in the given line and
remove labels which do not have a definition.
- Modify the return value of the `processBinaryAsm` and `process`
function to return with the label definition too.
- Demangle the label usages and the label definitions too.
2019-12-01 21:36:21 +01:00
Márton Csordás f4d0eb01f1 Jump to labels in assembly
- Parse the labels asynchronously when a new assembly result is set
to the compiler view.
- `Ctrl + click` on a label will bring us to the label definition.
Create new keyboard and mouse events to catch this.
- Create a new context sensitive option in the context menu. If no
label can be found in the clicked position, the menu option will not
be shown.
- Select the range of the label definition when jumping to a label.
2019-12-01 21:01:59 +01:00
Matt Godbolt 44d721c713 Merge pull request #1702 from csordasmarton/save_selections
Save the selections
2019-11-30 08:55:25 -06:00
Partouf fd444c6610 diff executor select bugfix 2019-11-29 15:33:28 +01:00
Partouf 20df44bec5 bugfixes for when diff view opens 2019-11-29 14:50:10 +01:00
Márton Csordás b8c420967d Save the selections
Save selections in the editors. This way the links or the embedded
views can scroll to and highlight the area of the saved selections.
2019-11-27 20:42:14 +01:00
Partouf 787edac591 bugfixes 2019-11-15 15:24:54 +01:00
Partouf de8854ff9e Merge remote-tracking branch 'matt/master' into difftype 2019-11-15 15:00:18 +01:00
Partouf 5352389b2d bugfix when executor is opened for the first time 2019-11-14 17:25:58 +01:00
Partouf 1a3399f34b some refactoring 2019-11-14 17:24:43 +01:00
Austin Morton 0d0a52e249 "Fix" cross origin monaco web workers
This is a workaround to make cross origin monaco web workers function
in spite of the monaco webpack plugin hijacking the MonacoEnvironment global.

see https://github.com/microsoft/monaco-editor-webpack-plugin/issues/42

This workaround wouldn't be so bad, if it didn't _also_ rely on *another* bug to
actually work.

The webpack plugin incorrectly uses
    window.__webpack_public_path__
when it should use
    __webpack_public_path__

see https://github.com/microsoft/monaco-editor-webpack-plugin/pull/63

We can leave __webpack_public_path__ with the correct value, which lets runtime chunk
loading continue to function correctly.

We can then set window.__webpack_public_path__ to the below handler, which lets us
fabricate a worker on the fly.

This is bad and I feel bad.
2019-11-13 23:36:14 -05:00
Austin Morton 419458530f Support serving static content externally 2019-11-13 23:35:53 -05:00
Partouf 84e3017448 lintfix 2019-11-11 23:17:28 +01:00
Partouf c6a350ca31 allow diffing executor panes 2019-11-11 22:57:02 +01:00
Partouf e669b06d75 able to select difftype for compiler result 2019-11-08 20:30:09 +01:00
Rubén Rincón 6269ef0132 Fix tabWidth not respecting settings
Closes #1671
2019-11-08 09:48:02 +01:00
Rubén Rincón 4b212407b2 Make Ctrl+S open the sharing popover
Need to consider if we should change the default
2019-11-06 16:20:35 +01:00
Patrick Quist ba7d53572c Merge pull request #1616 from mattgodbolt/staticlibs
Static library linking support
2019-11-06 14:47:46 +01:00
Rubén Rincón 3df310ce6e Fixes old links having tiny font scales 2019-11-06 13:50:18 +01:00
Rubén Rincón 6f2b56ea2f Unify dark colors 2019-11-05 10:28:51 +01:00
Rubén Rincón ae222b4a9d Simplify fontScale behaviour
Closes #1660
2019-11-05 09:36:18 +01:00
Rubén Rincón 9b31ce2da4 Sets ligatures to false by default
The setting name changed so the default applies to users
 who have visited the site between now and when it was pushed

As noticed by @vincentisambart on #1653, it turns out that having
 ligatures enabled by default is not a wise idea
2019-11-04 16:47:14 +01:00
Rubén Rincón f5b15536b8 Change link color for dark theme 2019-11-02 20:09:58 +01:00
Matt Godbolt a598d18987 Thanks to our patrons 2019-11-02 08:49:19 -05:00
Rubén Rincón 6e4ec410f1 Enable font ligatures by default
They can be disabled in the settings pane
Closes #1653
2019-11-01 16:27:03 +01:00