mirror of
https://github.com/house-of-abbey/GarminHomeAssistant.git
synced 2025-04-30 20:52:27 +00:00
Merge branch 'main' into 94-add-gps-reporting-to-the-background-service
This commit is contained in:
@ -15,6 +15,11 @@
|
||||
<style>
|
||||
@import url('https://unpkg.com/@catppuccin/palette/css/catppuccin.css');
|
||||
|
||||
body {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
}
|
||||
|
||||
html,
|
||||
body,
|
||||
#container {
|
||||
@ -212,6 +217,9 @@
|
||||
&[icon='download']::before {
|
||||
background-image: url(https://fonts.gstatic.com/s/i/short-term/release/materialsymbolsoutlined/download/default/48px.svg);
|
||||
}
|
||||
&[icon='copy']::before {
|
||||
background-image: url(https://fonts.gstatic.com/s/i/short-term/release/materialsymbolsoutlined/content_copy/default/48px.svg);
|
||||
}
|
||||
}
|
||||
}
|
||||
</style>
|
||||
@ -239,6 +247,12 @@
|
||||
icon="download"
|
||||
id="download"
|
||||
type="button"></button>
|
||||
<button
|
||||
title="Copy the content of the editor to the clipboard"
|
||||
class="icon"
|
||||
icon="copy"
|
||||
id="copy"
|
||||
type="button"></button>
|
||||
<input
|
||||
required
|
||||
autocomplete="new-password"
|
||||
|
10
web/main.js
10
web/main.js
@ -569,6 +569,13 @@ require(['vs/editor/editor.main'], async () => {
|
||||
document.querySelector('#menu_url').classList.add('invalid');
|
||||
}
|
||||
});
|
||||
document.querySelector('#copy').addEventListener('click', async (e) => {
|
||||
navigator.clipboard.writeText(model.getValue());
|
||||
toast({
|
||||
text: 'Copied!',
|
||||
color: 'var(--ctp-mocha-green)',
|
||||
});
|
||||
});
|
||||
|
||||
document.querySelector('#api_url').addEventListener('change', (e) => {
|
||||
api_url = e.target.value;
|
||||
@ -661,7 +668,8 @@ require(['vs/editor/editor.main'], async () => {
|
||||
i--;
|
||||
} while (
|
||||
i >= 0 &&
|
||||
word.word[i].toUpperCase() != word.word[i].toLowerCase()
|
||||
(word.word[i] == '_' ||
|
||||
word.word[i].toUpperCase() != word.word[i].toLowerCase())
|
||||
);
|
||||
i++;
|
||||
var range = {
|
||||
|
Reference in New Issue
Block a user