Skip to content

Commit

Permalink
Merge pull request #270 from Tour-360/dev
Browse files Browse the repository at this point in the history
Обновление до версии v2.1.0
  • Loading branch information
BorodinDK authored Oct 26, 2018
2 parents 87d6c41 + 019976a commit 198e351
Show file tree
Hide file tree
Showing 61 changed files with 687 additions and 137 deletions.
3 changes: 2 additions & 1 deletion bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@
"build/three.js",
"examples/js/renderers/CanvasRenderer.js",
"examples/js/renderers/Projector.js",
"examples/js/renderers/CSS3DRenderer.js"
"examples/js/renderers/CSS3DRenderer.js",
"examples/js/controls/DeviceOrientationControls.js"
]
}
}
Expand Down
2 changes: 1 addition & 1 deletion build/tour-player.css

Large diffs are not rendered by default.

40 changes: 21 additions & 19 deletions build/tour-player.js

Large diffs are not rendered by default.

74 changes: 74 additions & 0 deletions example/gallery.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,74 @@
<!doctype html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
<link rel="stylesheet" href="../build/tour-player.css">
<script src="../build/tour-player.js"></script>
<title>Example Tour-360 player</title>
<style>
/* Цвет всех маркеров */
#markers .button {
background-color: rgba(0,0,0,.8);
}

/* Цвет информационных маркеров */
#markers .button.info{
background-color: #ed1c24;
}

/* Цвет полосы загрузки */
#control-panel .progress-bar .value {
background: #ed1c24;
}
</style>
</head>
<body>
<div class="popup-layout">
<div class="popups">
<div class="close"></div>
<div class="popup" id="lana-del-rey-born-to-die">
<img src="http://cdn1.umg3.net/89/files/2014/06/Lana-Del-Rey-Born-To-Die-Paradise-Edition-1500x1500-2012.png" alt="Lana Del Rey — Born To Die: Paradise Edition">
<div class="content">
<h1>Lana Del Rey — Born To Die: Paradise Edition</h1>
<p>Другой альбом: <a href="#lana-del-rey-ultraviolence">Lana Del Rey — Ultraviolence</a></p>
<p><b>«Born to Die: The Paradise Edition»</b> — переиздание американской певицы Ланы Дель Рей студийного альбома Born to Die (2012). Выпущен 9 ноября 2012 года под лейблами Polydor и Interscope. Также одновременно с переизданием был выпущен мини-альбом Paradise, в который вошли 8 новых треков, которыми был дополнен оригинальный альбом. Рик Новелл и Эмили Хейни были единственными, кто работал над двумя этими сборниками вместе.</p>
<ol>
<li>«Born to Die»</li>
<li>«Off to the Races»</li>
<li>«Blue Jeans»</li>
<li>«Video Games»</li>
<li>«Diet Mountain Dew»</li>
<li>«National Anthem»</li>
<li>«Dark Paradise»</li>
<li>«Radio»</li>
<li>«Carmen»</li>
<li>«Million Dollar Man»</li>
<li>«Summertime Sadness»</li>
<li>«This Is What Makes Us Girls»</li>
<li>«Without You»</li>
<li>«Lolita»</li>
<li>«Lucky Ones»</li>
</ol>
</div>
</div>
<div class="popup" id="lana-del-rey-ultraviolence">
<img src="http://cdn1.umg3.net/89/files/2014/06/Lana-Del-Rey-Ultraviolence-2014-1500x1500.png" width="100" alt="Lana Del Rey — Ultraviolence">
<div class="content">
<h1>Lana Del Rey — Ultraviolence</h1>
<p>Другой альбом: <a href="#lana-del-rey-born-to-die">Lana Del Rey — Born To Die: Paradise Edition</a></p>
</div>
</div>
</div>
</div>

<script>
Tour.init(false, {
controlPanel: true
});
Tour.on('load', function(data) {
this.controls.autoRotate()
})
</script>
</body>
</html>
4 changes: 3 additions & 1 deletion example/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,9 @@ <h1>Lana Del Rey — Ultraviolence</h1>

<script>
Tour.init(false, {
controlPanel: true
controlPanel: true,
gallery: true,
galleryVisible: false
});
Tour.on('load', function(data) {
this.controls.autoRotate()
Expand Down
12 changes: 7 additions & 5 deletions example/manifest.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// specification: https://github.com/Tour-360/tour-player/wiki/Формат-файла-Data.json
{
"_specification": "https://github.com/Tour-360/tour-player/wiki/Формат-файла-Data.json",
"title": "Avant SHOP",
"start": 1,
"backgroundImage": "data:image/gif;base64,R0lGODdhCAAGAPIAAOjt86O4sp2np0tbTJKNi46gqLyyvcHK0iwAAAAACAAGAAADGhgGdxwiyFDEGaIckQ0mhtENhEBsFqFajJEAADs=",
Expand Down Expand Up @@ -31,7 +31,7 @@
"lon": -90,
"lat": 16,
"icon": "info",
"title": "<a href=\"https://ru.wikipedia.org/wiki/Linkin_Park\" target=\"_blank\">Linkin Park</a> — A Thousand Suns",
"title": "<a href=\"https://ru.wikipedia.org/wiki/Linkin_Park\" target=\"_blank\">Linkin Park</a> — A Thousand Suns",
"action": {
"type": "url",
"href": "https://ru.wikipedia.org/wiki/Linkin_Park"
Expand All @@ -41,6 +41,7 @@
},{
"id": 1,
"title": "Центр",
"listNumber": 2,
"lon": 0,
"lat": 0,
"markers": [
Expand All @@ -64,7 +65,7 @@
"lon": 280,
"lat": 13.73,
"icon": "info",
"title": "Lana Del Rey — Born To Die: Paradise Edition",
"title": "Lana Del Rey — Born To Die: Paradise Edition",
"action": {
"type": "popup",
"id": "lana-del-rey-born-to-die"
Expand All @@ -73,7 +74,7 @@
"lon": 292,
"lat": 3,
"icon": "info",
"title": "Lana Del Rey — Ultraviolence",
"title": "Lana Del Rey — Ultraviolence",
"action": {
"type": "popup",
"id": "lana-del-rey-ultraviolence"
Expand All @@ -83,6 +84,7 @@
},{
"id": 2,
"title": {"ru": "Касса", "en": "Сashbox"},
"listNumber": 1,
"lon": 0,
"lat": 0,
"markers": [
Expand All @@ -106,4 +108,4 @@
]
}
]
}
}
Binary file added example/panorams/0/thumbnail/mini.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added example/panorams/1/thumbnail/mini.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added example/panorams/2/thumbnail/mini.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
14 changes: 7 additions & 7 deletions gulpfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ gulp.task('scripts', function() {
return gulp.src([
'src/js/*.js',
'src/js/UI/*.js',
'src/js/**/*.js',
'src/js/**/*.js',
'src/lib/three.js',
'src/lib/*.js'])
.pipe(sourcemaps.init())
Expand Down Expand Up @@ -114,17 +114,17 @@ gulp.task('serve', ['build'], function() {

//Публикация на сайте tour-360.ru по FTP
gulp.task('deploy', function() {
gulp.src(['build/**/*', '!build/**/*.map'])
gulp.src(['build/**/*'])
.pipe(sftp({
host: 'tour-360.ru',
auth: 'beta',
remotePath: 'public_html/tour-player/latest'
auth: 'admin',
remotePath: '/var/www/tour-360.ru/tour-player/latest'
}));
gulp.src(['build/**/*', '!build/**/*.map'])
gulp.src(['build/**/*'])
.pipe(sftp({
host: 'tour-360.ru',
auth: 'beta',
remotePath: 'public_html/tour-player/' + pjson.version
auth: 'admin',
remotePath: '/var/www/tour-360.ru/tour-player/' + pjson.version
}));
});

Expand Down
26 changes: 13 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
{
"name": "tour-player",
"version": "2.0.0",
"version": "2.1.0",
"description": "",
"repository": {},
"repository": {
"type": "git",
"url": "https://github.com/Tour-360/tour-player"
},
"scripts": {
"postinstall": "./node_modules/bower/bin/bower i && ./node_modules/gulp/bin/gulp.js build",
"start": "node index.js",
"test": "gulp lint"
},
"repository": {
"type": "git",
"url": "https://github.com/Tour-360/tour-player"
},
"keywords": [
"tour",
"virtual",
Expand All @@ -23,13 +22,14 @@
"author": "Maxim Borodin <[email protected]> (http://maximborodin.ru)",
"contributors": [
{
"name" : "Maxim Borodin",
"email" : "[email protected]",
"url" : "http://maximborodin.ru"
},{
"name" : "Denis Borodin",
"email" : "[email protected]",
"url" : "http://denisborodin.ru"
"name": "Maxim Borodin",
"email": "[email protected]",
"url": "http://maximborodin.ru"
},
{
"name": "Denis Borodin",
"email": "[email protected]",
"url": "http://denisborodin.ru"
}
],
"license": "MIT",
Expand Down
Binary file modified src/.DS_Store
Binary file not shown.
16 changes: 16 additions & 0 deletions src/css/control-panel.styl
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,11 @@ $progress-bar-height = 3px
text-align center
z-index 1
opacity 0
left 0
bottom - $btn-size
transition all.4s ease
user-select none
touch-action none

&.visible
bottom 18px + $btn-size
Expand Down Expand Up @@ -56,6 +59,7 @@ $progress-bar-height = 3px
height $btn-size
background center no-repeat
cursor pointer
transition transform.3s ease

&:hover
background-color rgba(0, 0, 0, .05)
Expand All @@ -77,6 +81,18 @@ $progress-bar-height = 3px
background-image embedurl("../img/controls/zoom_out.svg", "utf8")
.fullscreen
background-image embedurl("../img/controls/fullscreen.svg", "utf8")
.rotate
background-image embedurl("../img/controls/rotate.svg", "utf8")

&[data-orientation="landscape-primary"]
.marker
transform rotate(-90deg)
&[data-orientation="landscape-secondary"]
.marker
transform rotate(90deg)
&[data-orientation="portrait-secondary"]
.marker
transform rotate(180deg)

body.fullscreen
#control-panel .fullscreen
Expand Down
1 change: 1 addition & 0 deletions src/css/dependences.styl
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@
@import "notification.styl"
@import "background-image.styl"
@import "popups.styl"
@import "gallery.styl"
88 changes: 88 additions & 0 deletions src/css/gallery.styl
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
#gallery
position absolute
width 200px
left -200px
height 100%
background rgba(0,0,0,.8)
z-index 2
transition left.3s ease
will-change left

&.visible
left 0

.gallery-toggler
cursor pointer
position absolute
background rgba(0,0,0,.8)
top 0
bottom 0
margin auto 0
right -18px
width 18px
height 50px
border-radius 0 5px 5px 0

&:after
content ''
display block
position absolute
top 0
right 0
bottom 0
left 0
background-image embedurl("../img/gallery-toogler.svg", "utf8")
background-position center
background-repeat no-repeat
transform scale(-1, 1)

&.visible
.gallery-toggler:after
transform scale(1, 1)

ul
margin 0
padding 5px
height 100%
overflow hidden
overflow-y scroll
box-sizing border-box

li
box-sizing border-box
background-size 100%
background-position center
position relative
cursor pointer
background-color #666
padding 0
margin 5px 0
box-shadow 0 0 0 0 white
transition box-shadow.1s ease


&.active
box-shadow 0 0 0 5px $blue

&:hover
box-shadow 0 0 0 2px white

&:before
content ''
height 0
display block
padding-top 50%

.item-title
position absolute
bottom 0
margin 0
background linear-gradient(to top,rgba(0,0,0,0.5) 40%, transparent)
color white
padding 24px 10px 8px
white-space nowrap
overflow hidden
text-overflow ellipsis
width 100%
box-sizing border-box

1 change: 1 addition & 0 deletions src/css/layout.styl
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ body
top 0
left 0
user-select none
touch-action none
Loading

0 comments on commit 198e351

Please sign in to comment.