Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
B
baas-ide
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
1
Merge Requests
1
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
guxukai
baas-ide
Commits
416d7906
Commit
416d7906
authored
Apr 03, 2019
by
LianaHus
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed fil-open icon and change the style of icons
parent
a007399a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
8 deletions
+9
-8
file-explorer.js
src/app/files/file-explorer.js
+5
-5
file-explorer-styles.js
src/app/files/styles/file-explorer-styles.js
+4
-3
No files found.
src/app/files/file-explorer.js
View file @
416d7906
...
@@ -63,6 +63,8 @@ function fileExplorer (localRegistry, files, menuItems) {
...
@@ -63,6 +63,8 @@ function fileExplorer (localRegistry, files, menuItems) {
fileManager
:
self
.
_components
.
registry
.
get
(
'filemanager'
).
api
fileManager
:
self
.
_components
.
registry
.
get
(
'filemanager'
).
api
}
}
self
.
_components
.
registry
.
put
({
api
:
self
,
name
:
`fileexplorer/
${
self
.
files
.
type
}
`
})
// warn if file changed outside of Remix
// warn if file changed outside of Remix
function
remixdDialog
()
{
function
remixdDialog
()
{
return
yo
`<div>This file has been changed outside of Remix IDE.</div>`
return
yo
`<div>This file has been changed outside of Remix IDE.</div>`
...
@@ -507,7 +509,7 @@ fileExplorer.prototype.renderMenuItems = function () {
...
@@ -507,7 +509,7 @@ fileExplorer.prototype.renderMenuItems = function () {
items
=
this
.
menuItems
.
map
(({
action
,
title
,
icon
})
=>
{
items
=
this
.
menuItems
.
map
(({
action
,
title
,
icon
})
=>
{
if
(
action
===
'uploadFile'
)
{
if
(
action
===
'uploadFile'
)
{
return
yo
`
return
yo
`
<label class="
${
icon
}
${
css
.
newFile
}
">
<label class="
${
icon
}
${
css
.
newFile
}
"
title="
${
title
}
"
>
<input type="file" onchange=
${(
event
)
=>
{
<input type="file" onchange=
${(
event
)
=>
{
event
.
stopPropagation
()
event
.
stopPropagation
()
this
.
uploadFile
(
event
)
this
.
uploadFile
(
event
)
...
@@ -516,14 +518,12 @@ fileExplorer.prototype.renderMenuItems = function () {
...
@@ -516,14 +518,12 @@ fileExplorer.prototype.renderMenuItems = function () {
`
`
} else {
} else {
return yo`
return yo`
<
span
onclick
=
$
{(
event
)
=>
{
event
.
stopPropagation
();
this
[
action
]()
}}
class
=
"newFile ${css.newFile}"
title
=
$
{
title
}
>
<
span
onclick
=
$
{(
event
)
=>
{
event
.
stopPropagation
();
this
[
action
]()
}}
class
=
"${icon} ${css.newFile}"
title
=
$
{
title
}
></span>
<i class=
${
icon
}
></i>
</span>
`
`
}
}
})
})
}
}
return
yo
`<span class=
${
css
.
menu
}
>
${
items
}
</span>`
return
yo
`<span class=
"
${
css
.
menu
}
"
>
${
items
}
</span>`
}
}
fileExplorer
.
prototype
.
ensureRoot
=
function
(
cb
)
{
fileExplorer
.
prototype
.
ensureRoot
=
function
(
cb
)
{
...
...
src/app/files/styles/file-explorer-styles.js
View file @
416d7906
...
@@ -3,6 +3,7 @@ var csjs = require('csjs-inject')
...
@@ -3,6 +3,7 @@ var csjs = require('csjs-inject')
var
css
=
csjs
`
var
css
=
csjs
`
.label {
.label {
margin-bottom : 0px;
margin-bottom : 0px;
margin-top : 4px
}
}
.fileexplorer {
.fileexplorer {
box-sizing : border-box;
box-sizing : border-box;
...
@@ -19,13 +20,13 @@ var css = csjs`
...
@@ -19,13 +20,13 @@ var css = csjs`
padding : 4px;
padding : 4px;
}
}
.newFile {
.newFile {
padding :
4
px;
padding :
5
px;
}
}
.newFile i {
.newFile i {
cursor : pointer;
cursor : pointer;
}
}
.newFile
i
:hover {
.newFile:hover {
color : var(--secondary)
transform : scale(1.3);
}
}
.menu {
.menu {
margin-left : 20px;
margin-left : 20px;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment