diff --git a/app/extensions/brave/locales/en-US/app.properties b/app/extensions/brave/locales/en-US/app.properties index 5c40df199fd..f231798bd6d 100644 --- a/app/extensions/brave/locales/en-US/app.properties +++ b/app/extensions/brave/locales/en-US/app.properties @@ -80,8 +80,8 @@ moreBookmarks=More bookmarks… fullScreenModeWarning={{host}} entered full screen mode, press ESC to exit. braveMenuTotalReplacements=Total Replacements: {{count}} basicAuthRequired=Authentication Required -basicAuthUsernameLabel=Username: -basicAuthPasswordLabel=Password: +basicAuthUsernameLabel=Username +basicAuthPasswordLabel=Password basicAuthMessage={{host}} requires a username and password. crashScreenHeader=Something went wrong =( crashScreenText=An error occurred while displaying this webpage. To continue, reload or navigate to another page. diff --git a/app/renderer/components/styles/commonStyles.js b/app/renderer/components/styles/commonStyles.js index e236134ac51..9ff64232c89 100644 --- a/app/renderer/components/styles/commonStyles.js +++ b/app/renderer/components/styles/commonStyles.js @@ -21,6 +21,20 @@ const styles = StyleSheet.create({ width: '100%' }, + // Textbox -- copied from textbox.js + textbox: { + boxSizing: 'border-box', + width: 'auto' + }, + textbox__outlineable: { + ':focus': { + outlineColor: globalStyles.color.statsBlue, + outlineOffset: '-4px', + outlineStyle: 'solid', + outlineWidth: '1px' + } + }, + // Dialogs flyoutDialog: { background: globalStyles.color.toolbarBackground, diff --git a/js/components/loginRequired.js b/js/components/loginRequired.js index f5f0a2fce78..3effecf24b5 100644 --- a/js/components/loginRequired.js +++ b/js/components/loginRequired.js @@ -10,6 +10,17 @@ const appActions = require('../actions/appActions') const KeyCodes = require('../../app/common/constants/keyCodes') const urlResolve = require('url').resolve +const { + CommonForm, + CommonFormSection, + CommonFormTitle, + CommonFormButtonWrapper +} = require('../../app/renderer/components/commonForm') + +const {StyleSheet, css} = require('aphrodite/no-important') +const globalStyles = require('../../app/renderer/components/styles/global') +const commonStyles = require('../../app/renderer/components/styles/commonStyles') + class LoginRequired extends React.Component { constructor () { super() @@ -74,31 +85,81 @@ class LoginRequired extends React.Component { host: urlResolve(this.detail.getIn(['request', 'url']), '/') } return -
-

-
-
-
-
- { - !this.isFolder - ?
-
+ + +

} } LoginRequired.propTypes = { frameProps: PropTypes.object } + +const styles = StyleSheet.create({ + sectionWrapper: { + display: 'flex', + justifyContent: 'space-between' + }, + inputWrapper: { + display: 'flex', + flexFlow: 'column', + justifyContent: 'space-around' + }, + inputWrapper__label: { + marginRight: `calc(${globalStyles.spacing.dialogInsideMargin} / 2)` + }, + inputWrapper__input: { + flexGrow: 1 + }, + input__bottomRow: { + marginTop: `calc(${globalStyles.spacing.dialogInsideMargin} / 3)` + }, + input__box: { + fontSize: globalStyles.fontSize.flyoutDialog + } +}) + module.exports = LoginRequired