RIFT-14134, RIFT-14548: RO CRU and Instantiate Data Centers
Signed-off-by: Laurence Maultsby <laurence.maultsby@riftio.com>
diff --git a/skyquake/framework/widgets/panel/panel.jsx b/skyquake/framework/widgets/panel/panel.jsx
index e8a3118..4ef7c89 100644
--- a/skyquake/framework/widgets/panel/panel.jsx
+++ b/skyquake/framework/widgets/panel/panel.jsx
@@ -1,5 +1,5 @@
/*
- *
+ *
* Copyright 2016 RIFT.IO Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -25,20 +25,21 @@
render() {
let self = this;
let {children, className, title, ...props} = self.props;
- let classRoot = className ? ' ' + className : ' '
+ let classRoot = className ? ' ' + className : ' ';
+ let hasCorners = this.props['no-corners'];
let titleTag = title ? <header className="skyquakePanel-title">{title}</header> : '';
return (
<section className={'skyquakePanel' + classRoot} style={props.style}>
- <i className="corner-accent top left"></i>
- <i className="corner-accent top right"></i>
+ { !hasCorners ? <i className="corner-accent top left"></i> : null }
+ { !hasCorners ? <i className="corner-accent top right"></i> : null }
{titleTag}
<div className="skyquakePanel-wrapper">
<div className={(classRoot ? 'skyquakePanel-body ' + decorateClassNames(classRoot, '-body') : 'skyquakePanel-body')}>
{children}
</div>
</div>
- <i className="corner-accent bottom left"></i>
- <i className="corner-accent bottom right"></i>
+ { !hasCorners ? <i className="corner-accent bottom left"></i> : null }
+ { !hasCorners ? <i className="corner-accent bottom right"></i> : null }
</section>
)
}
@@ -50,7 +51,8 @@
export class PanelWrapper extends Component {
render() {
- return (<div className={'skyquakePanelWrapper'}>
+ return (
+ <div className={'skyquakePanelWrapper ' + this.props.className} style={this.props.style}>
{this.props.children}
</div>)
}
@@ -60,7 +62,7 @@
function decorateClassNames(className, addendum) {
- return className.split(' ').map(function(c) {
+ return className.trim().split(' ').map(function(c) {
return c + addendum
}).join(' ');
}
diff --git a/skyquake/framework/widgets/panel/panel.scss b/skyquake/framework/widgets/panel/panel.scss
index ff36bbf..2a31b1c 100644
--- a/skyquake/framework/widgets/panel/panel.scss
+++ b/skyquake/framework/widgets/panel/panel.scss
@@ -1,5 +1,5 @@
/*
- *
+ *
* Copyright 2016 RIFT.IO Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -55,6 +55,12 @@
}
}
+.skyquakePanelWrapper.column {
+ .skyquakePanel-wrapper {
+ height:auto;
+ }
+}
+
/* Style for storybook */
body{
height:100%;
diff --git a/skyquake/framework/widgets/skyquake_container/skyquakeContainer.jsx b/skyquake/framework/widgets/skyquake_container/skyquakeContainer.jsx
index eca9413..53a382f 100644
--- a/skyquake/framework/widgets/skyquake_container/skyquakeContainer.jsx
+++ b/skyquake/framework/widgets/skyquake_container/skyquakeContainer.jsx
@@ -1,5 +1,5 @@
/*
- *
+ *
* Copyright 2016 RIFT.IO Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -83,7 +83,7 @@
}
render() {
- const {displayNotification, notificationMessage, displayScreenLoader, ...state} = this.state;
+ const {displayNotification, notificationMessage, displayScreenLoader, notificationType, ...state} = this.state;
var html;
if (this.matchesLoginUrl()) {
@@ -104,7 +104,7 @@
<Crouton
id={Date.now()}
message={notificationMessage}
- type={"error"}
+ type={notificationType}
hidden={!(displayNotification && notificationMessage)}
onDismiss={SkyquakeContainerActions.hideNotification}
/>
diff --git a/skyquake/framework/widgets/skyquake_container/skyquakeContainerSource.js b/skyquake/framework/widgets/skyquake_container/skyquakeContainerSource.js
index 2ee50c0..03bc7ef 100644
--- a/skyquake/framework/widgets/skyquake_container/skyquakeContainerSource.js
+++ b/skyquake/framework/widgets/skyquake_container/skyquakeContainerSource.js
@@ -1,5 +1,5 @@
/*
- *
+ *
* Copyright 2016 RIFT.IO Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
diff --git a/skyquake/framework/widgets/skyquake_container/skyquakeContainerStore.js b/skyquake/framework/widgets/skyquake_container/skyquakeContainerStore.js
index fe4a7b0..aa4e744 100644
--- a/skyquake/framework/widgets/skyquake_container/skyquakeContainerStore.js
+++ b/skyquake/framework/widgets/skyquake_container/skyquakeContainerStore.js
@@ -1,5 +1,5 @@
/*
- *
+ *
* Copyright 2016 RIFT.IO Inc
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -35,6 +35,7 @@
//Notification defaults
this.notificationMessage = '';
this.displayNotification = false;
+ this.notificationType = 'error';
//Screen Loader default
this.displayScreenLoader = false;
this.bindActions(SkyquakeContainerActions);
@@ -81,9 +82,9 @@
let connection = data.connection;
let streamSource = data.streamSource;
console.log('Success opening notification socket for stream ', streamSource);
-
+
let ws = window.multiplexer.channel(connection);
-
+
if (!connection) return;
self.setState({
socket: ws.ws,
@@ -162,20 +163,21 @@
//Notifications
showNotification = (data) => {
- if(typeof(data) == 'string') {
- this.setState({
+ let state = {
displayNotification: true,
- notificationMessage: data
- });
+ notificationMessage: data,
+ notificationType: 'error',
+ displayScreenLoader: false
+ }
+ if(typeof(data) == 'string') {
+
} else {
- if(data.type == 'error') {
- this.setState({
- displayNotification: true,
- notificationMessage: data.msg,
- displayScreenLoader: false
- });
+ state.notificationMessage = data.msg;
+ if(data.type == 'success') {
+ state.notificationType = 'success';
}
}
+ this.setState(state);
}
hideNotification = () => {
this.setState({