Skip to content

Commit e75b72d

Browse files
committed
Merge branch 'release/v2.0.6'
2 parents fd9e0cb + d69c797 commit e75b72d

12 files changed

+68
-37
lines changed

bower.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "shell.js",
3-
"version": "2.0.5",
3+
"version": "2.0.6",
44
"description": "A JavaScript and CSS library to create terminals",
55
"author": "Davide Caruso <davide.caruso93@gmail.com>",
66
"license": "MIT",

demo/index.html

+48-8
Original file line numberDiff line numberDiff line change
@@ -4,20 +4,60 @@
44
<meta charset="UTF-8">
55
<title>Shell.js</title>
66
<script src="https://cdnjs.cloudflare.com/ajax/libs/typed.js/2.0.6/typed.min.js"></script>
7-
<script src="../lib/shell.min.js"></script>
7+
<script src="../lib/shell.js"></script>
88
<script>
9-
document.addEventListener('DOMContentLoaded', function() {
10-
let shell = new Shell('#awesome-shell', {
11-
style: 'osx',
12-
commands: ['sudo -i'],
13-
typed: Typed
9+
document.addEventListener('DOMContentLoaded', function () {
10+
new Shell('#default', {
11+
user: 'guest',
12+
commands: ['sudo -i', 'rm -rf /', 'exit']
13+
});
14+
new Shell('#default-light', {
15+
user: 'guest',
16+
theme: 'light',
17+
commands: ['sudo -i', 'rm -rf /', 'exit']
18+
});
19+
new Shell('#osx', {
20+
user: 'guest',
21+
host: 'MacBook-Pro',
22+
style: 'osx',
23+
commands: ['sudo -i', 'rm -rf /', 'exit']
24+
});
25+
new Shell('#osx-light', {
26+
user: 'guest',
27+
host: 'MacBook-Pro',
28+
style: 'osx',
29+
theme: 'light',
30+
commands: ['sudo -i', 'rm -rf /', 'exit']
31+
});
32+
new Shell('#ubuntu', {
33+
user: 'guest',
34+
host: 'localhost',
35+
style: 'ubuntu',
36+
commands: ['sudo -i', 'rm -rf /', 'exit']
37+
});
38+
new Shell('#ubuntu-light', {
39+
user: 'guest',
40+
host: 'localhost',
41+
style: 'ubuntu',
42+
theme: 'light',
43+
commands: ['sudo -i', 'rm -rf /', 'exit']
44+
});
45+
new Shell('#windows', {
46+
style: 'windows',
47+
commands: ['sudo -i', 'rm -rf /', 'exit']
48+
});
1449
});
15-
});
1650
</script>
1751
</head>
1852
<body>
1953
<div id="container">
20-
<div id="awesome-shell"></div>
54+
<div id="default"></div>
55+
<div id="default-light"></div>
56+
<div id="osx"></div>
57+
<div id="osx-light"></div>
58+
<div id="ubuntu"></div>
59+
<div id="ubuntu-light"></div>
60+
<div id="windows"></div>
2161
</div>
2262
</body>
2363
</html>

lib/shell.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/shell.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/shell.min.js

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

lib/shell.min.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "shell.js",
3-
"version": "2.0.5",
3+
"version": "2.0.6",
44
"description": "A JavaScript and CSS library to create terminals",
55
"scripts": {
66
"test": "echo \"Error: no test specified\" && exit 1",

src/sass/helpers/_functions.scss

-6
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,3 @@
1-
/**
2-
* Replace all occurrences of the search string with the replacement string
3-
* @param $search: The value being searched for, otherwise known as the needle.
4-
* @param $replace: The replacement value that replaces found search values.
5-
* @param $subject: The string being searched and replaced on, otherwise known as the haystack.
6-
*/
71
@function str-replace($search, $replace, $subject, $all: false) {
82
$position-found: str-index($subject, $search);
93
$processed: ();

src/sass/themes/_default.scss

+1
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
text-align: center;
2323
margin: 0 2px;
2424
border-radius: 50%;
25+
cursor: pointer;
2526
@include size(15px, 15px);
2627
@include adjust-font(18px, 15px);
2728

src/sass/themes/_osx.scss

+7
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,17 @@
22
.status-bar {
33
border-color: #EBEBEB;
44
background-image: linear-gradient(to bottom, #EBEBEB 0%, #CBCBCB 100%);
5+
position: relative;
6+
7+
.buttons {
8+
position: absolute;
9+
height: 100%;
10+
}
511

612
.title {
713
color: $gray-text-color;
814
text-align: center;
15+
flex-grow: 100;
916
}
1017
}
1118

src/sass/themes/_ubuntu.scss

+4-11
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,17 @@
1111
color: #444444;
1212

1313
&:hover {
14-
color: #A21F2C;
14+
background: darken(#D75224, 5%);
15+
color: #444444;
1516
}
1617
}
1718

18-
&.icon-minimize {
19-
background: #898989;
20-
color: #555555;
21-
22-
&:hover {
23-
color: #555555;
24-
}
25-
}
26-
27-
&.icon-enlarge {
19+
&.icon-minimize, &.icon-enlarge {
2820
background: #898989;
2921
color: #555555;
3022

3123
&:hover {
24+
background: darken(#898989, 5%);
3225
color: #555555;
3326
}
3427
}

yarn.lock

-4
Original file line numberDiff line numberDiff line change
@@ -1289,10 +1289,6 @@ commondir@^1.0.1:
12891289
version "1.0.1"
12901290
resolved "https://registry.yarnpkg.com/commondir/-/commondir-1.0.1.tgz#ddd800da0c66127393cca5950ea968a3aaf1253b"
12911291

1292-
compass-mixins@^0.12.10:
1293-
version "0.12.10"
1294-
resolved "https://registry.yarnpkg.com/compass-mixins/-/compass-mixins-0.12.10.tgz#cd9f15f829c4e960cc43bb226f049b28beb99d41"
1295-
12961292
concat-map@0.0.1:
12971293
version "0.0.1"
12981294
resolved "https://registry.yarnpkg.com/concat-map/-/concat-map-0.0.1.tgz#d8a96bd77fd68df7793a73036a3ba0d5405d477b"

0 commit comments

Comments
 (0)