mirror of
https://github.com/chinchang/web-maker.git
synced 2025-06-11 12:11:06 +02:00
minor fixes and docs
This commit is contained in:
@ -214,6 +214,7 @@ export class SidePane extends Component {
|
|||||||
}
|
}
|
||||||
dropHandler(e) {
|
dropHandler(e) {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
|
// Object with `children` key is to simulate a folder structure for root folder
|
||||||
this.props.onFileDrop(e.dataTransfer.getData('text/plain'), {
|
this.props.onFileDrop(e.dataTransfer.getData('text/plain'), {
|
||||||
children: this.props.files
|
children: this.props.files
|
||||||
});
|
});
|
||||||
|
@ -1283,9 +1283,17 @@ export default class App extends Component {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
getRootClasses() {
|
||||||
|
const classes = [];
|
||||||
|
if (this.state.currentItem && this.state.currentItem.files) {
|
||||||
|
classes.push('is-file-mode');
|
||||||
|
}
|
||||||
|
return classes.join(' ');
|
||||||
|
}
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
return (
|
return (
|
||||||
<div>
|
<div class={this.getRootClasses()}>
|
||||||
<div class="main-container">
|
<div class="main-container">
|
||||||
<MainHeader
|
<MainHeader
|
||||||
externalLibCount={this.state.externalLibCount}
|
externalLibCount={this.state.externalLibCount}
|
||||||
|
@ -67,9 +67,9 @@
|
|||||||
</style>
|
</style>
|
||||||
</head>
|
</head>
|
||||||
|
|
||||||
<body class="is-project">
|
<body>
|
||||||
<!-- SCRIPT-TAGS -->
|
<!-- SCRIPT-TAGS -->
|
||||||
<%= htmlWebpackPlugin.options.ssr({
|
<%= htmlWebpackPlugin.options.ssr({
|
||||||
url: '/'
|
url: '/'
|
||||||
}) %>
|
}) %>
|
||||||
<script defer src="<%= htmlWebpackPlugin.files.chunks['bundle'].entry %>"></script>
|
<script defer src="<%= htmlWebpackPlugin.files.chunks['bundle'].entry %>"></script>
|
||||||
|
@ -387,7 +387,7 @@ body:not(.light-version).overlay-visible .main-container {
|
|||||||
width: auto;
|
width: auto;
|
||||||
}
|
}
|
||||||
|
|
||||||
.is-project .content-wrap {
|
.is-file-mode .content-wrap {
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -455,7 +455,7 @@ body:not(.light-version).overlay-visible .main-container {
|
|||||||
height: auto;
|
height: auto;
|
||||||
width: 33%;
|
width: 33%;
|
||||||
}
|
}
|
||||||
.is-project .code-wrap {
|
.is-file-mode .code-wrap {
|
||||||
flex-basis: 100%;
|
flex-basis: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1673,7 +1673,7 @@ body:not(.is-app) .show-when-app {
|
|||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.is-project .hide-in-file-mode {
|
.is-file-mode .hide-in-file-mode {
|
||||||
display: none !important;
|
display: none !important;
|
||||||
}
|
}
|
||||||
@media screen and (max-width: 600px) {
|
@media screen and (max-width: 600px) {
|
||||||
|
Reference in New Issue
Block a user