Skip to content

Commit

Permalink
ui fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Eugeny committed May 29, 2015
1 parent cef20e9 commit e3e1fd1
Show file tree
Hide file tree
Showing 28 changed files with 64 additions and 23 deletions.
2 changes: 1 addition & 1 deletion ajenti-core/aj/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

# imported by installer, no 3rd party imports here!

__version__ = '2.0.46'
__version__ = '2.0.47'

# Global state

Expand Down
1 change: 0 additions & 1 deletion ajenti-core/aj/http.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ def dispatch(self, env, start_response):

http_context.run_response()
gevent.sleep(0)
print http_context.path, repr(content)[:1000]
return content


Expand Down
2 changes: 1 addition & 1 deletion plugins/auth_users/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240898.74
1432911711.82
2 changes: 1 addition & 1 deletion plugins/core/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432241020.39
1432911881.34
3 changes: 2 additions & 1 deletion plugins/core/bower.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@
"ngstorage": "~0.3.0",
"fastclick": "~1.0.3",
"angular-sortable-view": "0.0.13",
"AngularJS-Toaster": "~0.4.9"
"AngularJS-Toaster": "~0.4.9",
"angular-base64": "~2.0.4"
},
"resolutions": {
"angular": "~1.4.0"
Expand Down
1 change: 1 addition & 0 deletions plugins/core/content/pages/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<head>
<title ng:bind="pageTitle + (pageTitle ? ' | ' : '') + identity.machine.name"></title>
<link rel="shortcut icon" />
<link rel="manifest" href="{{urlPrefix || '/'}}api/core/web-manifest" />

<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
Expand Down
3 changes: 2 additions & 1 deletion plugins/core/plugin.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: core
author: Ajenti project
email: e@ajenti.org
url: http://ajenti.org
version: '0.35'
version: '0.36'
title: Core
icon: link
dependencies: []
Expand All @@ -24,6 +24,7 @@ resources:
- 'resources/vendor/angular-sortable-view/src/angular-sortable-view.min.js'
- 'resources/vendor/ngstorage/ngStorage.min.js'
- 'resources/vendor/fastclick/lib/fastclick.js'
- 'resources/vendor/angular-base64/angular-base64.js'
- 'resources/css/bootstrap/bootstrap.less'
- 'resources/css/overrides.less'
- 'resources/css/animations.less'
Expand Down
21 changes: 21 additions & 0 deletions plugins/core/resources/css/animations.less
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,27 @@
}


.animate-modal {
transition: opacity ease 0.25s;
-moz-transition: opacity ease 0.25s;
-webkit-transition: opacity ease 0.25s;

&>.modal {
transition: margin ease 0.25s, opacity ease 0.25s;
-moz-transition: margin ease 0.25s, opacity ease 0.25s;
-webkit-transition: margin ease 0.25s, opacity ease 0.25s;
opacity: 1;
}
}

.animate-modal.ng-hide {
&>.modal {
margin-top: -50px;
opacity: 0;
}
}


.flip-cycle {
animation: flip-cycle-frames ease infinite 2s;
-moz-animation: flip-cycle-frames ease infinite 2s;
Expand Down
Binary file added plugins/core/resources/images/icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed plugins/core/resources/images/profile-normal.png
Binary file not shown.
Binary file removed plugins/core/resources/images/profile-root.png
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,6 @@ angular.module('core').controller 'CoreRootController', ($scope, $rootScope, $lo
identity.init()
identity.promise.then () ->
console.log 'Ready!'
.catch () ->
console.error 'Failed'

favicon.init()

Expand Down
3 changes: 2 additions & 1 deletion plugins/core/resources/js/core/directives/dialog.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ angular.module('core').directive 'dialog', ($http, $log) ->
restrict: 'E'
transclude: true
template: '''
<div class="modal" ng:show="attrs.ngShow || attrs.ngIf">
<div class="modal">
<div class="modal-dialog {{attrs.dialogClass}}">
<div class="modal-content">
<ng-transclude></ng-transclude>
Expand All @@ -13,6 +13,7 @@ angular.module('core').directive 'dialog', ($http, $log) ->
'''
link: ($scope, element, attrs) ->
element.addClass('block-element')
element.addClass('animate-modal')
$scope.attrs = attrs
$scope.$watch 'attrs.ngShow', () ->
if attrs.ngShow
Expand Down
1 change: 1 addition & 0 deletions plugins/core/resources/js/core/module.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ angular.module 'core', [
'toaster',
'ui.bootstrap',
'angular-sortable-view',
'base64',
]


Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
angular.module('core').service 'identity', ($http, $location, $window, $timeout, $q, urlPrefix) ->
q = $q.defer()
@promise = q.promise

@init = () ->
q = $q.defer()
@promise = q.promise
$http.get('/api/core/identity').success (data) =>
@user = data.identity.user
@uid = data.identity.uid
Expand Down
17 changes: 17 additions & 0 deletions plugins/core/views/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,23 @@ def handle_api_identity(self, http_context):
'color': aj.config.data.get('color', None),
}

@url('/api/core/web-manifest')
@endpoint(api=True, auth=False)
def handle_api_web_manifest(self, http_context):
return {
'short_name': aj.config.data['name'],
'name': '%s (%s)' % (aj.config.data['name'], socket.gethostname()),
'start_url': '%s/#app' % http_context.prefix,
'display': 'standalone',
'icons': [
{
'src': '%s/resources/core/resources/images/icon.png' % http_context.prefix,
'sizes': '1024x1024',
'type': 'image/png',
}
]
}

@url('/api/core/auth')
@endpoint(api=True, auth=False)
def handle_api_auth(self, http_context):
Expand Down
2 changes: 1 addition & 1 deletion plugins/dashboard/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240888.61
1432911702.45
2 changes: 1 addition & 1 deletion plugins/datetime/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240907.49
1432911719.77
2 changes: 1 addition & 1 deletion plugins/filemanager/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240905.75
1432911718.28
2 changes: 1 addition & 1 deletion plugins/network/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240897.07
1432911710.24
2 changes: 1 addition & 1 deletion plugins/notepad/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240890.29
1432911703.96
2 changes: 1 addition & 1 deletion plugins/packages/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240902.16
1432911715.14
2 changes: 1 addition & 1 deletion plugins/passwd/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240891.83
1432911705.35
2 changes: 1 addition & 1 deletion plugins/plugins/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240903.86
1432911716.64
2 changes: 1 addition & 1 deletion plugins/services/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240900.4
1432911713.46
2 changes: 1 addition & 1 deletion plugins/settings/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240893.48
1432911706.91
2 changes: 1 addition & 1 deletion plugins/supervisor/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240895.21
1432911708.54
2 changes: 1 addition & 1 deletion plugins/terminal/.last-upload
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1432240909.55
1432911721.43

0 comments on commit e3e1fd1

Please sign in to comment.