lanes 0.1.9.5 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile +1 -0
- data/Rakefile +1 -1
- data/client/lanes/Boot.cjsx +3 -3
- data/client/lanes/Config.coffee +38 -3
- data/client/lanes/access/Extension.coffee +1 -1
- data/client/lanes/access/LoginDialog.cjsx +57 -47
- data/client/lanes/access/Roles.coffee +2 -2
- data/client/lanes/access/User.coffee +4 -3
- data/client/lanes/access/screens/user-management/UserManagement.cjsx +12 -11
- data/client/lanes/components/calendar/Calendar.cjsx +16 -0
- data/client/lanes/components/calendar/index.js +3 -0
- data/client/lanes/components/calendar/styles.scss +3 -0
- data/client/lanes/components/grid/Body.cjsx +86 -0
- data/client/lanes/components/grid/CellStyles.coffee +20 -0
- data/client/lanes/components/grid/EditingMixin.cjsx +84 -24
- data/client/lanes/components/grid/Editor.cjsx +45 -0
- data/client/lanes/components/grid/Grid.cjsx +62 -104
- data/client/lanes/components/grid/Header.cjsx +35 -0
- data/client/lanes/components/grid/PopOverMixin.cjsx +19 -9
- data/client/lanes/components/grid/PopoverEditor.cjsx +7 -1
- data/client/lanes/components/grid/RowEditor.cjsx +1 -1
- data/client/lanes/components/grid/Selections.cjsx +39 -0
- data/client/lanes/components/grid/Toolbar.cjsx +24 -5
- data/client/lanes/components/grid/editors.scss +22 -50
- data/client/lanes/components/grid/index.js +0 -1
- data/client/lanes/components/grid/row-editor.scss +68 -0
- data/client/lanes/components/grid/styles.scss +79 -3
- data/client/lanes/components/modal/Modal.cjsx +64 -24
- data/client/lanes/components/modal/styles.scss +12 -0
- data/client/lanes/components/record-finder/Clause.cjsx +11 -4
- data/client/lanes/components/record-finder/Dialog.cjsx +23 -24
- data/client/lanes/components/record-finder/RecordFinder.cjsx +45 -14
- data/client/lanes/components/record-finder/styles.scss +9 -6
- data/client/lanes/components/select-field/SelectField.cjsx +108 -53
- data/client/lanes/components/select-field/styles.scss +19 -0
- data/client/lanes/components/shared/ControlLabel.cjsx +45 -0
- data/client/lanes/components/shared/DateTime.cjsx +48 -0
- data/client/lanes/components/shared/DisplayValue.cjsx +16 -0
- data/client/lanes/components/shared/FieldMixin.cjsx +54 -23
- data/client/lanes/components/shared/FieldSet.cjsx +12 -35
- data/client/lanes/components/shared/FieldWrapper.cjsx +13 -0
- data/client/lanes/components/shared/FormGroup.cjsx +37 -0
- data/client/lanes/components/shared/Icon.cjsx +20 -0
- data/client/lanes/components/shared/ImageSaver.cjsx +33 -0
- data/client/lanes/components/shared/Input.cjsx +19 -0
- data/client/lanes/components/shared/InputFieldMixin.cjsx +48 -0
- data/client/lanes/components/shared/JobProgress.cjsx +27 -0
- data/client/lanes/components/shared/NetworkActivityOverlay.cjsx +58 -0
- data/client/lanes/components/shared/NumberInput.cjsx +29 -0
- data/client/lanes/components/shared/ResizeSensor.cjsx +11 -0
- data/client/lanes/components/shared/ScreenWrapper.cjsx +13 -0
- data/client/lanes/components/shared/Throbber.cjsx +3 -0
- data/client/lanes/components/shared/ToggleField.cjsx +33 -0
- data/client/lanes/components/shared/Tooltip.cjsx +2 -2
- data/client/lanes/components/shared/fields.scss +75 -13
- data/client/lanes/components/shared/fieldset.scss +3 -5
- data/client/lanes/components/shared/image-saver.scss +38 -0
- data/client/lanes/components/shared/index.js +2 -0
- data/client/lanes/{styles/plugins → components/shared}/overlay.scss +17 -4
- data/client/lanes/components/shared/resize-sensor.scss +30 -0
- data/client/lanes/components/shared/styles.scss +13 -0
- data/client/lanes/components/shared/throbber.scss +53 -0
- data/client/lanes/components/toolbar/RemoteChangeSets.cjsx +21 -48
- data/client/lanes/components/toolbar/SaveButton.cjsx +24 -0
- data/client/lanes/components/toolbar/Toolbar.cjsx +24 -37
- data/client/lanes/components/toolbar/changes-notification.scss +10 -6
- data/client/lanes/components/toolbar/styles.scss +29 -9
- data/client/lanes/extension/Base.coffee +4 -5
- data/client/lanes/index.js +0 -1
- data/client/lanes/index.scss.erb +10 -1
- data/client/lanes/lib/HotReload.coffee +13 -15
- data/client/lanes/lib/MakeBaseClass.coffee +6 -1
- data/client/lanes/lib/development.coffee +2 -0
- data/client/lanes/lib/dom-polyfills.coffee +5 -0
- data/client/lanes/lib/dom.coffee +38 -9
- data/client/lanes/lib/format.coffee +11 -0
- data/client/lanes/lib/index.js.erb +2 -0
- data/client/lanes/lib/production.coffee +6 -0
- data/client/lanes/lib/utilFunctions.coffee +50 -15
- data/client/lanes/models/AssociationMap.coffee +122 -46
- data/client/lanes/models/AssociationProxy.coffee +147 -0
- data/client/lanes/models/Base.coffee +97 -85
- data/client/lanes/models/ChangeMonitor.coffee +7 -3
- data/client/lanes/models/ChangeSet.coffee +2 -2
- data/client/lanes/models/Collection.coffee +49 -6
- data/client/lanes/models/JobStatus.coffee +32 -0
- data/client/lanes/models/PubSub.coffee +7 -5
- data/client/lanes/models/Query.coffee +115 -34
- data/client/lanes/models/ServerCache.coffee +67 -52
- data/client/lanes/models/State.coffee +97 -0
- data/client/lanes/models/Sync.coffee +18 -13
- data/client/lanes/models/SystemSettings.coffee +0 -0
- data/client/lanes/models/index.js +1 -0
- data/client/lanes/models/mixins/FileSupport.coffee +60 -0
- data/client/lanes/models/mixins/HasCodeField.coffee +13 -6
- data/client/lanes/models/query/ArrayResult.coffee +188 -0
- data/client/lanes/models/query/CollectionResult.coffee +71 -0
- data/client/lanes/models/query/Result.coffee +9 -0
- data/client/lanes/react/Component.coffee +7 -3
- data/client/lanes/react/PubSub.coffee +7 -7
- data/client/lanes/react/Root.cjsx +1 -4
- data/client/lanes/react/Screen.coffee +1 -0
- data/client/lanes/react/TypeValidators.coffee +3 -3
- data/client/lanes/react/Viewport.coffee +41 -7
- data/client/lanes/react/index.js +0 -1
- data/client/lanes/react/mixins/Access.coffee +4 -1
- data/client/lanes/react/mixins/Data.coffee +40 -25
- data/client/lanes/react/mixins/FieldErrors.coffee +27 -0
- data/client/lanes/react/mixins/RelayEditingState.coffee +4 -0
- data/client/lanes/react/mixins/Screen.coffee +14 -0
- data/client/lanes/react/mixins/Viewport.coffee +9 -3
- data/client/lanes/screens/ChangeListener.coffee +3 -3
- data/client/lanes/screens/Commands.coffee +14 -7
- data/client/lanes/screens/CommonComponents.cjsx +20 -0
- data/client/lanes/screens/Definitions.coffee +64 -20
- data/client/lanes/screens/SystemSettings.cjsx +56 -0
- data/client/lanes/screens/UserPreferences.cjsx +38 -0
- data/client/lanes/screens/index.js +3 -0
- data/client/lanes/screens/styles.scss +2 -1
- data/client/lanes/styles/fonts.scss +1 -0
- data/client/lanes/styles/global.scss +2 -1
- data/client/lanes/styles/global/flexbox.scss +16 -0
- data/client/lanes/styles/global/styles.scss +1 -0
- data/client/lanes/styles/mixins/_dropdown.scss +21 -0
- data/client/lanes/styles/mixins/_flexbox.scss +394 -0
- data/client/lanes/styles/mixins/all.scss +2 -0
- data/client/lanes/styles/variables.scss +28 -0
- data/client/lanes/testing/BeforeEach.coffee +15 -14
- data/client/lanes/testing/Helpers.coffee +14 -5
- data/client/lanes/testing/TestObjects.coffee +10 -2
- data/client/lanes/testing/index.js +1 -0
- data/client/lanes/testing/jasmine-react.js +125 -0
- data/client/lanes/vendor/base.js +56049 -74987
- data/client/lanes/vendor/calendar.js +17301 -0
- data/client/lanes/vendor/calendar.scss +303 -0
- data/client/lanes/vendor/commons.js +14990 -15847
- data/client/lanes/vendor/development.js +4912 -1952
- data/client/lanes/vendor/grid.js +14246 -5551
- data/client/lanes/vendor/grid.scss +876 -335
- data/client/lanes/vendor/index.js +1 -0
- data/client/lanes/vendor/message-bus-ajax.js +44 -0
- data/client/lanes/vendor/message-bus.js +414 -0
- data/client/lanes/vendor/rw-widgets.eot +0 -0
- data/client/lanes/vendor/rw-widgets.svg +18 -0
- data/client/lanes/vendor/rw-widgets.ttf +0 -0
- data/client/lanes/vendor/rw-widgets.woff +0 -0
- data/client/lanes/vendor/toggle.js +345 -0
- data/client/lanes/vendor/toggle.scss +138 -0
- data/client/lanes/vendor/widgets.js +21245 -6839
- data/client/lanes/vendor/widgets.scss +83 -67
- data/client/lanes/workspace/Layout.cjsx +18 -8
- data/client/lanes/workspace/Modal.cjsx +47 -0
- data/client/lanes/workspace/Navbar.cjsx +16 -2
- data/client/lanes/workspace/ScreenView.cjsx +10 -3
- data/client/lanes/workspace/ScreensMenu.cjsx +23 -7
- data/client/lanes/workspace/Tabs.cjsx +55 -0
- data/client/lanes/workspace/UIState.coffee +7 -8
- data/client/lanes/workspace/index.js +2 -1
- data/client/lanes/workspace/mixin.coffee +11 -0
- data/client/lanes/workspace/mixins/UIState.coffee +8 -0
- data/client/lanes/workspace/mixins/index.js +3 -0
- data/client/lanes/workspace/styles.scss +2 -1
- data/client/lanes/workspace/styles/header.scss +23 -1
- data/client/lanes/workspace/styles/layout.scss +26 -24
- data/client/lanes/workspace/styles/screens.scss +0 -4
- data/client/lanes/workspace/styles/tabs.scss +3 -10
- data/config/routes.rb +10 -4
- data/config/screens.rb +25 -0
- data/db/migrate/01_create_system_settings.rb +10 -0
- data/docs/todo-example-part-1.md +18 -20
- data/lanes.gemspec +15 -6
- data/lib/lanes.rb +4 -2
- data/lib/lanes/access/config/routes.rb +5 -3
- data/lib/lanes/access/config/screens.rb +1 -0
- data/lib/lanes/access/db/migrate/20140615031600_create_lanes_users.rb +1 -1
- data/lib/lanes/access/user.rb +1 -1
- data/lib/lanes/api.rb +2 -1
- data/lib/lanes/api/controller.rb +32 -71
- data/lib/lanes/api/default_routes.rb +10 -8
- data/lib/lanes/api/formatted_reply.rb +53 -0
- data/lib/lanes/api/handlers/file.rb +26 -0
- data/lib/lanes/api/helper_methods.rb +29 -5
- data/lib/lanes/api/javascript_processor.rb +36 -17
- data/lib/lanes/api/pub_sub.rb +6 -9
- data/lib/lanes/api/request_wrapper.rb +1 -2
- data/lib/lanes/api/root.rb +11 -43
- data/lib/lanes/api/routing.rb +63 -0
- data/lib/lanes/api/sprockets_extension.rb +15 -7
- data/lib/lanes/api/updates.rb +1 -2
- data/lib/lanes/command.rb +0 -1
- data/lib/lanes/command/app.rb +6 -5
- data/lib/lanes/command/console.rb +1 -0
- data/lib/lanes/command/generate.rb +3 -0
- data/lib/lanes/command/generate_migration.rb +33 -0
- data/lib/lanes/command/generate_model.rb +4 -26
- data/lib/lanes/command/migration_support.rb +29 -0
- data/lib/lanes/command/update_model.rb +14 -5
- data/lib/lanes/concerns/all.rb +2 -0
- data/lib/lanes/concerns/api_path.rb +4 -2
- data/lib/lanes/concerns/association_extensions.rb +1 -1
- data/lib/lanes/concerns/attr_accessor_with_default.rb +3 -1
- data/lib/lanes/concerns/code_identifier.rb +1 -1
- data/lib/lanes/concerns/image_uploader.rb +42 -0
- data/lib/lanes/concerns/pub_sub.rb +0 -1
- data/lib/lanes/concerns/queries.rb +2 -2
- data/lib/lanes/concerns/set_attribute_data.rb +4 -13
- data/lib/lanes/concerns/sorting_expressions.rb +34 -0
- data/lib/lanes/configuration.rb +48 -9
- data/lib/lanes/extension.rb +16 -7
- data/lib/lanes/extension/definition.rb +8 -2
- data/lib/lanes/job.rb +78 -0
- data/lib/lanes/job/failure_logger.rb +33 -0
- data/lib/lanes/model.rb +4 -0
- data/lib/lanes/rake_tasks.rb +6 -0
- data/lib/lanes/redis.rb +13 -0
- data/lib/lanes/screen.rb +34 -18
- data/lib/lanes/system_settings.rb +66 -0
- data/lib/lanes/version.rb +1 -1
- data/lib/lanes/workspace/extension.rb +1 -1
- data/npm-build/base.js +10 -3
- data/npm-build/calendar.js +6 -0
- data/npm-build/development.js +4 -5
- data/npm-build/grid.js +3 -5
- data/npm-build/package.json +40 -29
- data/npm-build/react-toggle.js +5 -0
- data/npm-build/react-widgets.js +6 -0
- data/npm-build/update-dayz +14 -0
- data/npm-build/webpack.config.js +5 -2
- data/spec/command-reference-files/initial/Gemfile +1 -1
- data/spec/command-reference-files/initial/config/routes.rb +2 -0
- data/spec/command-reference-files/initial/lib/appy-app.rb +4 -0
- data/spec/command-reference-files/initial/lib/appy-app/extension.rb +2 -0
- data/spec/command-reference-files/initial/spec/server/{spec_helpers.rb → spec_helper.rb} +0 -0
- data/spec/command-reference-files/model/config/routes.rb +2 -0
- data/spec/command-reference-files/model/spec/server/test_test_spec.rb +1 -1
- data/spec/command-reference-files/screen/client/appy-app/screens/ready-set-go/ReadySetGo.cjsx +6 -4
- data/spec/command-reference-files/screen/client/appy-app/screens/ready-set-go/index.scss +4 -3
- data/spec/command-reference-files/screen/config/screens.rb +4 -2
- data/spec/command-reference-files/screen/spec/appy-app/screens/ready-set-go/ReadySetGoSpec.coffee +1 -1
- data/spec/fixtures/system_settings.yml +1 -0
- data/spec/lanes/components/grid/GridSpec.coffee +56 -31
- data/spec/lanes/components/grid/RowEditorSpec.coffee +96 -0
- data/spec/lanes/components/select-field/SelectFieldSpec.coffee +99 -0
- data/spec/lanes/components/shared/NetworkActivityOverlaySpec.coffee +34 -0
- data/spec/lanes/models/AssociationMapSpec.coffee +36 -2
- data/spec/lanes/models/AssociationProxySpec.coffee +77 -0
- data/spec/lanes/models/BaseSpec.coffee +37 -4
- data/spec/lanes/models/CollectionSpec.coffee +11 -17
- data/spec/lanes/models/PubSubSpec.coffee +1 -1
- data/spec/lanes/models/ServerCacheSpec.coffee +65 -0
- data/spec/server/api/coffeescript_processor_spec.rb +1 -1
- data/spec/server/concerns/pub_sub_spec.rb +9 -10
- data/spec/server/concerns/sorting_expressions_spec.rb +34 -0
- data/spec/server/configuration_spec.rb +3 -3
- data/spec/server/job_spec.rb +54 -0
- data/spec/server/spec_helper.rb +0 -5
- data/spec/server/system_settings_spec.rb +23 -0
- data/templates/client/screens/Screen.cjsx +6 -4
- data/templates/client/screens/styles.scss +4 -3
- data/templates/config/routes.rb +2 -0
- data/templates/config/screen.rb +4 -2
- data/templates/lib/namespace.rb +4 -0
- data/templates/lib/namespace/extension.rb +2 -0
- data/templates/spec/client/Screen.coffee +1 -1
- data/templates/spec/server/model_spec.rb +1 -1
- data/templates/spec/server/{spec_helpers.rb → spec_helper.rb} +0 -0
- data/views/lanes_root_view.erb +70 -0
- data/views/specs.erb +2 -2
- metadata +207 -68
- data/client/images/lanes/dataTables/Sorting icons.psd +0 -0
- data/client/images/lanes/dataTables/back_disabled.png +0 -0
- data/client/images/lanes/dataTables/back_enabled.png +0 -0
- data/client/images/lanes/dataTables/back_enabled_hover.png +0 -0
- data/client/images/lanes/dataTables/favicon.ico +0 -0
- data/client/images/lanes/dataTables/forward_disabled.png +0 -0
- data/client/images/lanes/dataTables/forward_enabled.png +0 -0
- data/client/images/lanes/dataTables/forward_enabled_hover.png +0 -0
- data/client/images/lanes/dataTables/loading-background.png +0 -0
- data/client/images/lanes/dataTables/sort_asc.png +0 -0
- data/client/images/lanes/dataTables/sort_asc_disabled.png +0 -0
- data/client/images/lanes/dataTables/sort_both.png +0 -0
- data/client/images/lanes/dataTables/sort_desc.png +0 -0
- data/client/images/lanes/dataTables/sort_desc_disabled.png +0 -0
- data/client/lanes/components/shared/Resize.cjsx +0 -152
- data/client/lanes/components/shared/TextArea.cjsx +0 -19
- data/client/lanes/components/shared/TextField.cjsx +0 -25
- data/client/lanes/models/Bootstrap.coffee +0 -5
- data/client/lanes/models/QueryResults.coffee +0 -93
- data/client/lanes/react/FormBindings.coffee +0 -103
- data/client/lanes/react/Router.cjsx +0 -18
- data/client/lanes/styles/dataTables.scss +0 -4
- data/client/lanes/styles/plugins/all.scss +0 -2
- data/client/lanes/styles/plugins/resize-sensor.scss +0 -24
- data/client/lanes/vendor/jquery-2.js +0 -9190
- data/client/lanes/vendor/jquery.tap.js +0 -401
- data/client/lanes/vendor/magicsuggest.js +0 -1565
- data/client/lanes/vendor/message-bus.coffee +0 -264
- data/client/lanes/workspace/ActiveScreenSwitcher.cjsx +0 -38
- data/client/lanes/workspace/styles/toolbar.scss +0 -4
- data/lib/lanes/api/eco.js +0 -516
- data/lib/lanes/api/sprockets_compressor.rb +0 -39
- data/spec/command-reference-files/model/lib/appy-app.rb +0 -11
- data/views/index.erb +0 -19
@@ -1,4 +1,11 @@
|
|
1
1
|
class Lanes.Workspace.Navbar extends Lanes.React.Component
|
2
|
+
dataObjects:
|
3
|
+
settings: -> Lanes.config.system_settings
|
4
|
+
|
5
|
+
propTypes:
|
6
|
+
history: React.PropTypes.shape(
|
7
|
+
push: React.PropTypes.func
|
8
|
+
).isRequired
|
2
9
|
|
3
10
|
contextTypes:
|
4
11
|
uistate: React.PropTypes.object.isRequired
|
@@ -10,16 +17,23 @@ class Lanes.Workspace.Navbar extends Lanes.React.Component
|
|
10
17
|
_.classnames 'header-top', @model.screen_menu_preference,
|
11
18
|
"menu-hidden": !@model.screen_menu_shown
|
12
19
|
|
20
|
+
Logo: ->
|
21
|
+
if @settings.logo?.url
|
22
|
+
<img src={@settings.logo.thumb.url} />
|
23
|
+
else
|
24
|
+
<span>Lanes</span>
|
25
|
+
|
13
26
|
render: ->
|
27
|
+
|
14
28
|
<div className="header-top">
|
15
29
|
<div className="navbar-header">
|
16
30
|
<a className="navbar-brand logo" href="#">
|
17
|
-
|
31
|
+
<@Logo />
|
18
32
|
</a>
|
19
33
|
<button className="screens-menu-toggle" onClick={@switchMenu} type="button">
|
20
34
|
<span className="sr-only">Toggle navbar</span>
|
21
35
|
<i className="icon"></i>
|
22
36
|
</button>
|
23
37
|
</div>
|
24
|
-
<Lanes.Workspace.
|
38
|
+
<Lanes.Workspace.Tabs history={@props.history} />
|
25
39
|
</div>
|
@@ -1,10 +1,10 @@
|
|
1
1
|
Screen = React.createClass
|
2
2
|
|
3
|
+
displayName: 'Screen'
|
3
4
|
shouldComponentUpdate: ->
|
4
5
|
false
|
5
|
-
|
6
6
|
render: ->
|
7
|
-
React.createElement(@props.component)
|
7
|
+
React.createElement(@props.screen.component(), @props.screen.props)
|
8
8
|
|
9
9
|
class Lanes.Workspace.ScreenView extends Lanes.React.Component
|
10
10
|
contextTypes:
|
@@ -12,16 +12,23 @@ class Lanes.Workspace.ScreenView extends Lanes.React.Component
|
|
12
12
|
|
13
13
|
dataObjects:
|
14
14
|
displaying: -> Lanes.Screens.Definitions.displaying
|
15
|
+
allScreens: -> Lanes.Screens.Definitions.all
|
15
16
|
|
16
17
|
bindDataEvents:
|
17
18
|
displaying: 'change:active remove add'
|
19
|
+
allScreens: 'change:loading'
|
18
20
|
|
19
21
|
renderScreen: (screen) ->
|
20
22
|
<div key={screen.id} className={_.classnames("screen", active:screen.active)}>
|
21
|
-
<Screen
|
23
|
+
<Screen screen={screen} />
|
22
24
|
</div>
|
23
25
|
|
26
|
+
renderLoading: ->
|
27
|
+
screen = Lanes.Screens.Definitions.all.findWhere(loading: true)
|
28
|
+
<LC.NetworkActivityOverlay visible model={screen} message="Loading #{screen.title}…" />
|
29
|
+
|
24
30
|
render: ->
|
25
31
|
<div className={"page-content #{@context.uistate.layout_size}"}>
|
32
|
+
{@renderLoading() if Lanes.Screens.Definitions.all.isLoading()}
|
26
33
|
{@displaying.map @renderScreen}
|
27
34
|
</div>
|
@@ -1,40 +1,56 @@
|
|
1
1
|
class ScreenList extends Lanes.React.Component
|
2
|
+
propTypes:
|
3
|
+
history: React.PropTypes.shape(
|
4
|
+
push: React.PropTypes.func
|
5
|
+
).isRequired
|
2
6
|
|
3
7
|
activateScreen: ->
|
4
|
-
@model.display()
|
8
|
+
@model.display().then (screen) =>
|
9
|
+
@props.history.push(screen.historyUrl())
|
5
10
|
|
6
11
|
render: ->
|
7
12
|
<li>
|
8
13
|
<a href="#" onClick={@activateScreen}>
|
9
|
-
<span>{@model.title}</span><
|
14
|
+
<span>{@model.title}</span><LC.Icon type={@model.icon} />
|
10
15
|
</a>
|
11
16
|
</li>
|
12
17
|
|
13
18
|
|
14
19
|
class ScreenGroup extends Lanes.React.Component
|
15
20
|
|
21
|
+
propTypes:
|
22
|
+
history: React.PropTypes.shape(
|
23
|
+
push: React.PropTypes.func
|
24
|
+
).isRequired
|
25
|
+
|
16
26
|
toggleActive: ->
|
17
27
|
@model.active = !@model.active
|
18
28
|
undefined
|
19
29
|
|
20
30
|
render: ->
|
21
|
-
screens = @model.screens().map (list)
|
22
|
-
<ScreenList model=list key=list.id />
|
31
|
+
screens = @model.screens().map (list) =>
|
32
|
+
<ScreenList {...@props} model=list key=list.id />
|
23
33
|
|
24
34
|
<li className={_.classnames("group", active: @model.active)} onClick={@toggleActive}>
|
25
35
|
<a className="heading" href="#">
|
26
|
-
<span>{@model.title}</span
|
36
|
+
<span>{@model.title}</span>
|
37
|
+
<i className={"icon icon-#{@model.icon}"}></i>
|
27
38
|
</a>
|
28
39
|
<ul>{screens}</ul>
|
29
40
|
</li>
|
30
41
|
|
31
42
|
class Lanes.Workspace.ScreensMenu extends Lanes.React.Component
|
32
43
|
|
44
|
+
propTypes:
|
45
|
+
history: React.PropTypes.shape(
|
46
|
+
push: React.PropTypes.func
|
47
|
+
).isRequired
|
48
|
+
|
33
49
|
dataObjects:
|
34
50
|
user: -> Lanes.current_user
|
35
51
|
|
36
52
|
renderGroup: (group) ->
|
37
|
-
<ScreenGroup model=group key=group.id />
|
53
|
+
<ScreenGroup {...@props} model=group key=group.id />
|
38
54
|
|
39
55
|
logOut: ->
|
40
56
|
Lanes.current_user.logout()
|
@@ -50,7 +66,7 @@ class Lanes.Workspace.ScreensMenu extends Lanes.React.Component
|
|
50
66
|
<li className="group logout" data-tooltip-message="Log Out" data-placement="right">
|
51
67
|
<a href="#" name="LogOut" onClick={@logOut}>
|
52
68
|
<span>Log Out</span>
|
53
|
-
<
|
69
|
+
<LC.Icon type='times' />
|
54
70
|
</a>
|
55
71
|
</li>
|
56
72
|
</ul>
|
@@ -0,0 +1,55 @@
|
|
1
|
+
class TabView extends Lanes.React.Component
|
2
|
+
|
3
|
+
setDataState: (nextState) ->
|
4
|
+
if @model.active
|
5
|
+
_.dom(document.head).qs('title').text = @model.title()
|
6
|
+
@props.history.replace(@model.historyUrl())
|
7
|
+
if Lanes.Screens.Definitions.displaying.length is 0
|
8
|
+
@props.history.push('/')
|
9
|
+
@setState(nextState)
|
10
|
+
|
11
|
+
propTypes:
|
12
|
+
history: React.PropTypes.shape(
|
13
|
+
push: React.PropTypes.func
|
14
|
+
).isRequired
|
15
|
+
|
16
|
+
activate: ->
|
17
|
+
@props.history.push(@model.historyUrl())
|
18
|
+
null
|
19
|
+
|
20
|
+
close: -> @model.remove()
|
21
|
+
|
22
|
+
render: ->
|
23
|
+
<li key={@model.cid} className={_.classnames(active: @model.active)}>
|
24
|
+
<a onClick={@activate} className='tab'>{@model.title()}</a>
|
25
|
+
<LC.Icon type={@model.screen.icon} />
|
26
|
+
<span onClick={@close} className='close'>×</span>
|
27
|
+
</li>
|
28
|
+
|
29
|
+
|
30
|
+
class Lanes.Workspace.Tabs extends Lanes.React.Component
|
31
|
+
propTypes:
|
32
|
+
history: React.PropTypes.shape(
|
33
|
+
push: React.PropTypes.func
|
34
|
+
).isRequired
|
35
|
+
|
36
|
+
dataObjects:
|
37
|
+
collection: -> Lanes.Screens.Definitions.displaying
|
38
|
+
|
39
|
+
render: ->
|
40
|
+
<div className="menu-container">
|
41
|
+
<div className="active-screens">
|
42
|
+
<div className="scroller scroller-left">
|
43
|
+
<i className="glyphicon glyphicon-chevron-left"/>
|
44
|
+
</div>
|
45
|
+
<div className="scroller scroller-right">
|
46
|
+
<i className="glyphicon glyphicon-chevron-right"/>
|
47
|
+
</div>
|
48
|
+
<div className="wrapper">
|
49
|
+
<ul className="nav nav-tabs">
|
50
|
+
{ @collection.map (view) =>
|
51
|
+
<TabView {...@props} key={view.id} model=view /> }
|
52
|
+
</ul>
|
53
|
+
</div>
|
54
|
+
</div>
|
55
|
+
</div>
|
@@ -14,14 +14,13 @@ class Lanes.Workspace.UIState extends Lanes.Models.State
|
|
14
14
|
type: 'string',
|
15
15
|
values: [ 'menu-wide', 'menu-narrow', 'menu-hidden' ]
|
16
16
|
}
|
17
|
-
root:
|
18
|
-
menu_view:
|
19
|
-
width:
|
20
|
-
height:
|
17
|
+
root: 'element'
|
18
|
+
menu_view: 'any'
|
19
|
+
width: 'number'
|
20
|
+
height: 'number'
|
21
|
+
layout: 'state'
|
22
|
+
viewport: 'object'
|
21
23
|
screen_menu_shown: 'boolean'
|
22
|
-
layout: 'state'
|
23
|
-
modalDialog: 'react'
|
24
|
-
viewport: 'object'
|
25
24
|
|
26
25
|
derived:
|
27
26
|
menu_width:
|
@@ -54,7 +53,7 @@ class Lanes.Workspace.UIState extends Lanes.Models.State
|
|
54
53
|
|
55
54
|
screens_width:
|
56
55
|
deps: ['width', 'screen_menu_size'], fn: ->
|
57
|
-
@width - @menu_width
|
56
|
+
@width - ( if @popover_menu then 0 else @menu_width )
|
58
57
|
|
59
58
|
screens_height:
|
60
59
|
deps: ['height'], fn: ->
|
@@ -1,3 +1,5 @@
|
|
1
|
+
$workspace-header-height: 50px;
|
2
|
+
|
1
3
|
@import "lanes/styles/bootstrap";
|
2
4
|
@import "lanes/styles/fonts";
|
3
5
|
// extensions are rooted at .lanes
|
@@ -12,6 +14,5 @@
|
|
12
14
|
@import "styles/header";
|
13
15
|
@import "styles/tabs";
|
14
16
|
@import "styles/screens";
|
15
|
-
@import "styles/toolbar";
|
16
17
|
@import "styles/forms";
|
17
18
|
@import "styles/keybindings";
|
@@ -3,7 +3,7 @@
|
|
3
3
|
@extend .navbar-inverse;
|
4
4
|
@extend .navbar-fixed-top;
|
5
5
|
z-index: 20;
|
6
|
-
height:
|
6
|
+
height: $workspace-header-height;
|
7
7
|
border-radius: 0;
|
8
8
|
margin: 0;
|
9
9
|
border: 0;
|
@@ -25,6 +25,12 @@
|
|
25
25
|
color: rgb(205, 208, 212);
|
26
26
|
font-size: 30px;
|
27
27
|
text-shadow: rgb(143, 112, 112) 2px 2px 4px;
|
28
|
+
padding: 0;
|
29
|
+
overflow: hidden;
|
30
|
+
img {
|
31
|
+
width: 100%;
|
32
|
+
height: 100%;
|
33
|
+
}
|
28
34
|
}
|
29
35
|
|
30
36
|
.navbar-toggle, .screens-menu-toggle {
|
@@ -39,4 +45,20 @@
|
|
39
45
|
margin: 12px 0 12px 0px;
|
40
46
|
border-radius: 0;
|
41
47
|
}
|
48
|
+
|
49
|
+
.nav-tabs {
|
50
|
+
li {
|
51
|
+
i {
|
52
|
+
position: absolute;
|
53
|
+
left: 2px;
|
54
|
+
top: 2px;
|
55
|
+
font-size: 12px;
|
56
|
+
color: darken(#333333, 10%);
|
57
|
+
}
|
58
|
+
&.active i {
|
59
|
+
color: lightgrey;
|
60
|
+
}
|
61
|
+
}
|
62
|
+
}
|
63
|
+
|
42
64
|
}
|
@@ -1,38 +1,42 @@
|
|
1
|
+
.layout {
|
2
|
+
height: 100%;
|
3
|
+
.header-top, .screens-menu {
|
4
|
+
position: fixed;
|
5
|
+
}
|
6
|
+
}
|
7
|
+
|
8
|
+
.page-container {
|
9
|
+
height: calc(100% - #{$workspace-header-height});
|
10
|
+
.screens-menu {
|
11
|
+
width: 240px;
|
12
|
+
z-index: 20;
|
13
|
+
left: 0;
|
14
|
+
top: 50px;
|
15
|
+
bottom: 0;
|
16
|
+
}
|
17
|
+
}
|
1
18
|
|
2
19
|
.page-content {
|
3
20
|
@extend .container-fluid;
|
21
|
+
overflow-x: hidden;
|
4
22
|
position: relative;
|
5
|
-
|
23
|
+
top: 50px;
|
6
24
|
transition: all 0.15s ease-in-out 0s;
|
7
25
|
margin-left: 240px;
|
8
|
-
padding:
|
9
|
-
|
26
|
+
padding: 0 0 20px 0;
|
27
|
+
height: 100%;
|
10
28
|
.screen {
|
29
|
+
height: 100%;
|
11
30
|
display: none;
|
31
|
+
> div { min-height: 100%; }
|
12
32
|
&.active {
|
13
33
|
display: block
|
14
34
|
}
|
15
35
|
}
|
16
|
-
|
17
|
-
}
|
18
|
-
|
19
|
-
|
20
|
-
.page-container {
|
21
|
-
.screens-menu {
|
22
|
-
width: 240px;
|
23
|
-
z-index: 26;
|
24
|
-
left: 0;
|
25
|
-
top: 50px;
|
26
|
-
position: absolute;
|
27
|
-
bottom: 0;
|
28
|
-
}
|
29
36
|
}
|
30
37
|
|
31
38
|
.screens-menu {
|
32
|
-
|
33
39
|
background-color: $navbar-inverse-bg;
|
34
|
-
|
35
|
-
|
36
40
|
.navigation {
|
37
41
|
border-bottom: 1px solid $navbar-inverse-border;
|
38
42
|
list-style: none outside none;
|
@@ -110,8 +114,6 @@
|
|
110
114
|
}
|
111
115
|
}
|
112
116
|
}
|
113
|
-
|
114
|
-
|
115
117
|
.logout>a {
|
116
118
|
border-bottom: 2px solid #49565d;
|
117
119
|
i {
|
@@ -119,7 +121,6 @@
|
|
119
121
|
top: 6px;
|
120
122
|
}
|
121
123
|
}
|
122
|
-
|
123
124
|
}
|
124
125
|
}
|
125
126
|
|
@@ -205,12 +206,13 @@
|
|
205
206
|
}
|
206
207
|
}
|
207
208
|
|
208
|
-
|
209
|
+
|
210
|
+
.popover_menu {
|
209
211
|
.page-content {
|
210
212
|
margin-left: 0px;
|
211
213
|
}
|
212
214
|
.screens-menu {
|
213
215
|
|
214
216
|
}
|
215
|
-
|
217
|
+
|
216
218
|
}
|
@@ -12,7 +12,7 @@
|
|
12
12
|
overflow-x: visible;
|
13
13
|
overflow-y: auto;
|
14
14
|
border: 0;
|
15
|
-
top:
|
15
|
+
top: 0;
|
16
16
|
transition: all 0.15s ease-in-out 0s;
|
17
17
|
overflow-x: visible;
|
18
18
|
overflow-y: auto;
|
@@ -42,7 +42,7 @@
|
|
42
42
|
overflow:hidden;
|
43
43
|
padding:5px;
|
44
44
|
height:45px;
|
45
|
-
|
45
|
+
top: 5px;
|
46
46
|
}
|
47
47
|
.nav {
|
48
48
|
position:absolute;
|
@@ -122,10 +122,8 @@
|
|
122
122
|
}
|
123
123
|
|
124
124
|
.active-screens {
|
125
|
-
|
126
|
-
height: 45px;
|
125
|
+
height: 50px;
|
127
126
|
padding: 0 5px;
|
128
|
-
|
129
127
|
.nav-tabs {
|
130
128
|
border-bottom: 0;
|
131
129
|
position: absolute;
|
@@ -138,11 +136,6 @@
|
|
138
136
|
top: 0px;
|
139
137
|
}
|
140
138
|
|
141
|
-
/* a { */
|
142
|
-
/* white-space: nowrap; */
|
143
|
-
/* } */
|
144
|
-
|
145
139
|
}
|
146
140
|
|
147
|
-
|
148
141
|
}
|