# HG changeset patch # User salimr # Date 1535721258 -7200 # Node ID 57d63a248f0da48ad67331e0fb63c297ca52571f # Parent 97536386b3974f4bab98a64765263c260c58bac4 Update to Bootstrap 4 diff -r 97536386b397 -r 57d63a248f0d client/package.json --- a/client/package.json Wed Aug 29 11:02:36 2018 +0200 +++ b/client/package.json Fri Aug 31 15:14:18 2018 +0200 @@ -5,6 +5,8 @@ "homepage": ".", "dependencies": { "@types/react-modal": "^3.2.1", + "bootstrap": "^4.1.3", + "i18next": "^11.6.0", "immutable": "^3.8.1", "jwt-decode": "^2.2.0", "localforage": "^1.5.0", @@ -39,8 +41,8 @@ "react-test-renderer": "^15.5.4" }, "scripts": { - "build-css": "node-sass-chokidar --include-path ./src --include-path ./src/sass --include-path ./node_modules --include-path ./node_modules/bootstrap-sass/assets/stylesheets src/ -o src/", - "watch-css": "npm run build-css && node-sass-chokidar --include-path ./src --include-path ./src/sass --include-path ./node_modules --include-path ./node_modules/bootstrap-sass/assets/stylesheets src/ -o src/ --watch --recursive", + "build-css": "node-sass-chokidar --include-path ./src --include-path ./src/scss --include-path ./node_modules src/ -o src/", + "watch-css": "npm run build-css && node-sass-chokidar --include-path ./src --include-path ./src/scss --include-path ./node_modules src/ -o src/ --watch --recursive", "start-js": "react-scripts start", "start": "npm-run-all -p watch-css start-js", "build": "npm run build-css && react-scripts build", diff -r 97536386b397 -r 57d63a248f0d client/src/App.js --- a/client/src/App.js Wed Aug 29 11:02:36 2018 +0200 +++ b/client/src/App.js Fri Aug 31 15:14:18 2018 +0200 @@ -1,4 +1,5 @@ import React, { Component } from 'react'; + // import logo from './logo.svg'; import './App.css'; import Navbar from './components/Navbar'; @@ -10,8 +11,8 @@
-
- +
+
Bienvenue sur
IRI Notes
diff -r 97536386b397 -r 57d63a248f0d client/src/App.scss --- a/client/src/App.scss Wed Aug 29 11:02:36 2018 +0200 +++ b/client/src/App.scss Fri Aug 31 15:14:18 2018 +0200 @@ -1,4 +1,5 @@ -@import "bootstrap/variables"; +@import 'bootstrap/scss/functions'; +@import 'bootstrap/scss/variables'; .App { text-align: center; @@ -142,7 +143,7 @@ padding: 20px 10px 20px 80px; margin-bottom: 10px; cursor: pointer; - min-height: ($line-height-computed * 4); + // min-height: ($line-height-computed * 4); border: 1px solid transparent; &:before { diff -r 97536386b397 -r 57d63a248f0d client/src/components/CreateGroup.js --- a/client/src/components/CreateGroup.js Wed Aug 29 11:02:36 2018 +0200 +++ b/client/src/components/CreateGroup.js Fri Aug 31 15:14:18 2018 +0200 @@ -41,7 +41,7 @@ renderErrorMessage(errorMessages, fieldname) { if (errorMessages && fieldname in errorMessages) { return errorMessages[fieldname].map((message, key) => -

{ message }

+

{ message }

); } } @@ -75,25 +75,25 @@
-
+
-
-

New Group

+
+

Créer un groupe

- - + + { this.renderErrorMessage(errorMessages, 'name') }
- + { this.renderErrorMessage(errorMessages, 'description') }
{ this.renderNonFieldErrors(errorMessages) }
-
+
diff -r 97536386b397 -r 57d63a248f0d client/src/components/Login.js --- a/client/src/components/Login.js Wed Aug 29 11:02:36 2018 +0200 +++ b/client/src/components/Login.js Fri Aug 31 15:14:18 2018 +0200 @@ -3,7 +3,7 @@ import { bindActionCreators } from 'redux'; import '../App.css'; import './Login.css'; -import Navbar from './Navbar'; +// import Navbar from './Navbar'; import * as authActions from '../actions/authActions'; class Login extends Component { @@ -32,7 +32,6 @@ submit = (e) => { e.preventDefault(); - this.login(); } @@ -44,7 +43,7 @@ renderErrorMessage(errorMessages, fieldname) { if (errorMessages && errorMessages.has(fieldname)) { return errorMessages.get(fieldname).map((message, key) => -

{ message }

+

{ message }

); } } @@ -64,30 +63,30 @@ render() { - const errorMessages = this.props.login.get('errorMessages'); + // const errorMessages = this.props.login.get('errorMessages'); return (
- + {/* */}
-
+
-
-

IRI Notes

+
+

IRI Notes

-
- - - { this.renderErrorMessage(errorMessages, 'username') } +
+ + + {/* { this.renderErrorMessage(errorMessages, 'username') } */}
-
- - - { this.renderErrorMessage(errorMessages, 'password') } +
+ + + {/* { this.renderErrorMessage(errorMessages, 'password') } */}
- { this.renderNonFieldErrors(errorMessages) } - + {/* { this.renderNonFieldErrors(errorMessages) } */} +
diff -r 97536386b397 -r 57d63a248f0d client/src/components/Login.scss --- a/client/src/components/Login.scss Wed Aug 29 11:02:36 2018 +0200 +++ b/client/src/components/Login.scss Fri Aug 31 15:14:18 2018 +0200 @@ -3,10 +3,10 @@ font-weight: bolder; } -.control-label { - color: #769FED; +label.col-form-label.text-primary { font-size: 16px; margin-left: 20%; + font-weight: bolder; } .form-control { @@ -26,9 +26,3 @@ margin-left: 35%; margin-top: 7%; } - -.text-center .text-muted { - color: #769FED; - font-size: 16px; - font-weight: bold; -} diff -r 97536386b397 -r 57d63a248f0d client/src/components/Navbar.js --- a/client/src/components/Navbar.js Wed Aug 29 11:02:36 2018 +0200 +++ b/client/src/components/Navbar.js Fri Aug 31 15:14:18 2018 +0200 @@ -12,14 +12,15 @@ import { groupSetCurrent } from '../actions/groupActions'; import { isAuthenticated, getCurrentUser, getOnline, getCurrentGroup, getGroups } from '../selectors/authSelectors'; import { isSynchronizing, isSynchronized } from '../selectors/syncSelectors'; +import CreateSession from './CreateSession'; import NavbarLogin from './NavbarLogin'; import NavbarGroup from './NavbarGroup'; const Online = ({ online }) => { return ( -
  • - - signal_wifi_4_bar +
  • + + signal_wifi_4_bar
  • ) @@ -40,8 +41,8 @@ if (isAuthenticated) { return ( -
  • - +
  • +
  • ); @@ -62,6 +63,10 @@ this.state = { modalIsOpen: false }; } + componentWillMount() { + Modal.setAppElement('body'); +} + openModal = () => { this.setState({modalIsOpen: true}); } @@ -129,24 +134,29 @@ render() { return ( -