Skip to content

Commit 14da7a0

Browse files
committed
Fix the panels size/resize
1 parent 846e801 commit 14da7a0

8 files changed

Lines changed: 81 additions & 10 deletions

File tree

dist/hyperapp-devtools.js

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/hyperapp-devtools.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/hyperapp-devtools.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

examples/index.html

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,9 @@ <h1>Devtools examples</h1>
1717
<li>
1818
<a href="./todos.html">Todo list</a>
1919
</li>
20+
<li>
21+
<a href="./long-names.html">Test Long state name (for test purpose only)</a>
22+
</li>
2023
</ul>
2124
</body>
2225

examples/long-names.html

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
<!DOCTYPE html>
2+
<html>
3+
4+
<head>
5+
<meta charset="utf-8" />
6+
<meta http-equiv="X-UA-Compatible" content="IE=edge">
7+
<title>Counter example with debugger</title>
8+
<meta name="viewport" content="width=device-width, initial-scale=1">
9+
10+
<script src="https://unpkg.com/hyperapp"></script>
11+
<script src="hyperapp-devtools.js"></script>
12+
</head>
13+
14+
<body>
15+
<p>Note: this is example is meant to show how the devtools handles overflow, it is not meant to represent a functional/usefull
16+
app.</p>
17+
<div id="app" />
18+
<br />
19+
<br />
20+
<a href="index.html">&nbsp;Back to index</a>
21+
22+
<script>
23+
const h = hyperapp.h
24+
25+
const state = {
26+
value: 0,
27+
loooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooogName: 0,
28+
}
29+
30+
const actions = {
31+
noop: value => ({}),
32+
loooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooogName: () => (state, actions) => {
33+
actions.noop()
34+
actions.noop()
35+
actions.noop()
36+
actions.noop()
37+
actions.noop()
38+
actions.noop()
39+
actions.noop()
40+
actions.noop()
41+
actions.noop()
42+
actions.noop()
43+
actions.noop()
44+
actions.noop()
45+
actions.noop()
46+
actions.noop()
47+
48+
return {
49+
value: state.value + 1000,
50+
loooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooogName: state.value + 1000
51+
}
52+
}
53+
}
54+
55+
const view = (state, actions) => (
56+
h("div", { style: { margin: "2rem" } },
57+
h("h1", { style: { margin: "0.5rem" } }, state.value),
58+
h("button", { onclick: actions.loooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooogName }, "+1000"),
59+
)
60+
)
61+
62+
devtools(hyperapp.app)(state, actions, view, document.getElementById("app"))
63+
64+
</script>
65+
66+
</body>
67+
68+
</html>

src/components/ObjectDetailsPane.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.object-details-pane {
2-
flex-grow: 1;
2+
flex: 0 0 60%;
33
border: 1px solid #666666;
44
margin: 0.1rem;
55

src/components/RunsPane.scss

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
.runs-pane {
2-
flex-grow: 0.8;
2+
flex: 0 0 40%;
33
border: 1px solid #666666;
44
margin: 0.1rem;
55

src/components/index.scss

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@
22

33
.scrollable {
44
display: flex;
5-
flex-direction: column;
5+
overflow: auto;
66

77
.scrollable-content {
8-
overflow-x: auto;
9-
overflow-y: auto;
8+
display: flex;
109
min-height: 0px;
10+
min-width: 0px;
1111
flex-grow: 1;
1212
}
1313
}

0 commit comments

Comments
 (0)