forked from ezsystems/PlatformUIBundle
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
EZP-23767: create new translation basing on existing one
- Loading branch information
Showing
24 changed files
with
2,203 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
/** | ||
* Copyright (C) eZ Systems AS. All rights reserved. | ||
* For full copyright and license information view LICENSE file distributed with this source code. | ||
*/ | ||
|
||
.is-languageselectionbox-hidden .ez-languageselectionbox-container { | ||
display: -webkit-box; | ||
display: -webkit-flex; | ||
display: -ms-flexbox; | ||
display: flex; | ||
|
||
background: #000; | ||
-webkit-transform: translateY(-100%); | ||
transform: translateY(-100%); | ||
} | ||
|
||
.ez-languageselectionbox-container { | ||
background: rgba(0, 0, 0, 0.6); | ||
transition: all 0.3s; | ||
|
||
-webkit-transform: translateY(0); | ||
transform: translateY(0); | ||
} | ||
|
||
.ez-view-languageselectionboxview { | ||
background: #D8D8D8; | ||
border: 1px solid #aaa; | ||
border-radius: 3px; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-title { | ||
font-size: 130%; | ||
font-weight: normal; | ||
color: #666; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-languages { | ||
background: #fff; | ||
border: solid 1px #aaa; | ||
border-radius: 3px; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-translation { | ||
cursor: pointer; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-translation:hover { | ||
background: #DDF5FF; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-translation.is-translation-selected { | ||
background: #CCE4FF; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-close-icon:after { | ||
color: #444; | ||
font-size: 150%; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-confirm { | ||
font-weight: bold; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,88 @@ | ||
/** | ||
* Copyright (C) eZ Systems AS. All rights reserved. | ||
* For full copyright and license information view LICENSE file distributed with this source code. | ||
*/ | ||
|
||
.ez-languageselectionbox-container { | ||
position: fixed; | ||
width: 100%; | ||
height: 100%; | ||
top: 0; | ||
left: 0; | ||
z-index: 21000; | ||
|
||
display: -webkit-box; | ||
display: -webkit-flex; | ||
display: -ms-flexbox; | ||
display: flex; | ||
} | ||
|
||
.is-languageselectionbox-hidden .ez-languageselectionbox-container { | ||
display: none; | ||
} | ||
|
||
.ez-view-languageselectionboxview { | ||
position: relative; | ||
display: inline-block; | ||
margin: auto; | ||
padding: 1.5em 2.2em; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-title { | ||
margin: 0; | ||
padding-bottom: 0.2em; | ||
text-align: left; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-close-icon { | ||
position: absolute; | ||
top: 0.2em; | ||
right: 0.2em; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-basetranslation { | ||
display: block; | ||
text-align: right; | ||
margin: 1em 0; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-languages { | ||
display: block; | ||
width: 30em; | ||
overflow: hidden; | ||
padding: 10px 0; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-translation { | ||
float: left; | ||
width: 12em; | ||
margin: 0 1em; | ||
padding: 0.3em 0.5em; | ||
list-style-type: none; | ||
line-height: 1.8em; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-existingtranslations-container { | ||
display: none; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-basetranslation-area { | ||
display: none; | ||
} | ||
|
||
.ez-view-languageselectionboxview.is-base-translation-allowed .ez-languageselectionbox-basetranslation-area { | ||
display: block; | ||
} | ||
|
||
.ez-view-languageselectionboxview.is-base-translations-list-visible .ez-languageselectionbox-existingtranslations-container { | ||
display: block; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-tools { | ||
text-align: right; | ||
margin: 2em 0 0 0; | ||
} | ||
|
||
.ez-view-languageselectionboxview .ez-languageselectionbox-confirm { | ||
margin-left: 2em; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
42 changes: 42 additions & 0 deletions
42
Resources/public/js/apps/plugins/ez-languageselectionboxplugin.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
/* | ||
* Copyright (C) eZ Systems AS. All rights reserved. | ||
* For full copyright and license information view LICENSE file distributed with this source code. | ||
*/ | ||
YUI.add('ez-languageselectionboxplugin', function (Y) { | ||
"use strict"; | ||
/** | ||
* Provides the language selection box plugin | ||
* | ||
* @module ez-languageselectionboxplugin | ||
*/ | ||
Y.namespace('eZ.Plugin'); | ||
|
||
/** | ||
* The language selection box plugin. It's a plugin the application to set up the | ||
* `languageSelect`, `languageSelected` and `cancelLanguageSelection` event handlers. | ||
* | ||
* @namespace eZ.Plugin | ||
* @class LanguageSelectionBox | ||
* @constructor | ||
* @extends Plugin.Base | ||
*/ | ||
Y.eZ.Plugin.LanguageSelectionBox = Y.Base.create('languageSelectionBoxPlugin', Y.Plugin.Base, [], { | ||
initializer: function () { | ||
var app = this.get('host'); | ||
|
||
app.on('*:languageSelect', function (e) { | ||
app.showSideView('languageSelectionBox', e.config); | ||
}); | ||
|
||
app.on(['*:languageSelected', '*:cancelLanguageSelection'], function (e) { | ||
app.hideSideView('languageSelectionBox'); | ||
}); | ||
}, | ||
}, { | ||
NS: 'languageSelectionBox', | ||
}); | ||
|
||
Y.eZ.PluginRegistry.registerPlugin( | ||
Y.eZ.Plugin.LanguageSelectionBox, ['platformuiApp'] | ||
); | ||
}); |
Oops, something went wrong.