Skip to content

Commit

Permalink
release: v1.15.4
Browse files Browse the repository at this point in the history
  • Loading branch information
surunzi committed Nov 3, 2024
1 parent 0239a03 commit ae22de5
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 12 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 1.15.4 (3 Nov 2024)

* fix: auto change theme

## 1.15.3 (27 Oct 2024)

* fix: embedded mode not resizable on mobile [#81](https://github.com/liriliri/chii/issues/81)
Expand Down
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "chii",
"version": "1.15.3",
"version": "1.15.4",
"description": "Chrome devtools framework",
"main": "./server/index.js",
"bin": {
Expand Down Expand Up @@ -50,9 +50,9 @@
"globals": "^15.6.0",
"gulp": "^4.0.2",
"gulp-clean": "^0.4.0",
"luna-data-grid": "^1.0.0",
"luna-modal": "^1.2.3",
"luna-toolbar": "^0.5.8",
"luna-data-grid": "^1.1.0",
"luna-modal": "^1.3.0",
"luna-toolbar": "^0.7.0",
"ncp": "^2.0.0",
"style-loader": "^3.3.1",
"svg-url-loader": "^8.0.0",
Expand Down
6 changes: 6 additions & 0 deletions server/tpl/index.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,12 @@
z-index: 1;
margin-bottom: 8px;
}
.toolbar > div:first-child {
margin-left: 0;
}
.toolbar > div:last-child {
margin-right: 0;
}
.description {
margin: 1rem 0;
font-size: .875rem;
Expand Down
12 changes: 4 additions & 8 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import detectOs from 'licia/detectOs';
import $ from 'licia/$';
import randomId from 'licia/randomId';
import toInt from 'licia/toInt';
import isDarkMode from 'licia/isDarkMode';
import LunaDataGrid from 'luna-data-grid';
import LunaModal from 'luna-modal';
import LunaToolbar from 'luna-toolbar';
Expand Down Expand Up @@ -64,21 +63,18 @@ const $toolbar = $('.toolbar');
const $help = $('.help');
const $description = $('.description');

const theme = isDarkMode() ? 'dark' : 'light';

const help = new LunaModal($help.get(0) as HTMLElement, {
theme,
theme: 'auto',
title: 'Help',
content: $description.get(0) as HTMLElement,
});

const toolbar = new LunaToolbar($toolbar.get(0) as HTMLElement, {
theme,
theme: 'auto',
});
toolbar.appendInput('filter', '', 'Filter');
const targets = toolbar.appendText('0 Target');
toolbar.appendSpace();
toolbar.appendInput('filter', '', 'Filter');
toolbar.appendSeparator();
toolbar.appendButton('Help', () => {
$description.rmClass('hidden');
help.show();
Expand All @@ -90,7 +86,7 @@ toolbar.on('change', (key, val) => {
});

const dataGrid = new LunaDataGrid($targets.get(0) as HTMLElement, {
theme,
theme: 'auto',
columns: [
{
id: 'title',
Expand Down

0 comments on commit ae22de5

Please sign in to comment.