Merge pull request #1210 from processing/remove-titles
fixes #1206, removes titles where it is unneccesary
This commit is contained in:
commit
287ea0d0aa
10 changed files with 3 additions and 66 deletions
|
@ -113,9 +113,6 @@ export const HIDE_ERROR_MODAL = 'HIDE_ERROR_MODAL';
|
||||||
export const PERSIST_STATE = 'PERSIST_STATE';
|
export const PERSIST_STATE = 'PERSIST_STATE';
|
||||||
export const CLEAR_PERSISTED_STATE = 'CLEAR_PERSISTED_STATE';
|
export const CLEAR_PERSISTED_STATE = 'CLEAR_PERSISTED_STATE';
|
||||||
|
|
||||||
export const SHOW_HELP_MODAL = 'SHOW_HELP_MODAL';
|
|
||||||
export const HIDE_HELP_MODAL = 'HIDE_HELP_MODAL';
|
|
||||||
|
|
||||||
export const HIDE_RUNTIME_ERROR_WARNING = 'HIDE_RUNTIME_ERROR_WARNING';
|
export const HIDE_RUNTIME_ERROR_WARNING = 'HIDE_RUNTIME_ERROR_WARNING';
|
||||||
export const SHOW_RUNTIME_ERROR_WARNING = 'SHOW_RUNTIME_ERROR_WARNING';
|
export const SHOW_RUNTIME_ERROR_WARNING = 'SHOW_RUNTIME_ERROR_WARNING';
|
||||||
export const SET_ASSETS = 'SET_ASSETS';
|
export const SET_ASSETS = 'SET_ASSETS';
|
||||||
|
|
|
@ -232,19 +232,6 @@ export function hideErrorModal() {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
export function showHelpModal(helpType) {
|
|
||||||
return {
|
|
||||||
type: ActionTypes.SHOW_HELP_MODAL,
|
|
||||||
helpType
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
export function hideHelpModal() {
|
|
||||||
return {
|
|
||||||
type: ActionTypes.HIDE_HELP_MODAL
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
export function hideRuntimeErrorWarning() {
|
export function hideRuntimeErrorWarning() {
|
||||||
return {
|
return {
|
||||||
type: ActionTypes.HIDE_RUNTIME_ERROR_WARNING
|
type: ActionTypes.HIDE_RUNTIME_ERROR_WARNING
|
||||||
|
|
|
@ -77,7 +77,7 @@ class Console extends React.Component {
|
||||||
});
|
});
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={consoleClass} role="main" title="console">
|
<div className={consoleClass} role="main">
|
||||||
<div className="preview-console__header">
|
<div className="preview-console__header">
|
||||||
<h2 className="preview-console__header-title">Console</h2>
|
<h2 className="preview-console__header-title">Console</h2>
|
||||||
<div className="preview-console__header-buttons">
|
<div className="preview-console__header-buttons">
|
||||||
|
|
|
@ -70,7 +70,6 @@ class CopyableInput extends React.Component {
|
||||||
rel="noopener noreferrer"
|
rel="noopener noreferrer"
|
||||||
href={value}
|
href={value}
|
||||||
className="copyable-input__preview"
|
className="copyable-input__preview"
|
||||||
title={`open ${label.toLowerCase()} view in new tab`}
|
|
||||||
>
|
>
|
||||||
<InlineSVG src={shareUrl} alt={`open ${label} view in new tab`} />
|
<InlineSVG src={shareUrl} alt={`open ${label} view in new tab`} />
|
||||||
</a>
|
</a>
|
||||||
|
|
|
@ -312,7 +312,6 @@ class Editor extends React.Component {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<section
|
<section
|
||||||
title="code editor"
|
|
||||||
role="main"
|
role="main"
|
||||||
className={editorSectionClass}
|
className={editorSectionClass}
|
||||||
>
|
>
|
||||||
|
|
|
@ -1,24 +0,0 @@
|
||||||
import React from 'react';
|
|
||||||
|
|
||||||
function HTTPSModal() {
|
|
||||||
return (
|
|
||||||
<section className="help-modal">
|
|
||||||
<div className="help-modal__section">
|
|
||||||
<div>
|
|
||||||
<p>Use the checkbox to choose whether this sketch should be loaded using HTTPS or HTTP.</p>
|
|
||||||
<p>You should choose HTTPS if you need to:</p>
|
|
||||||
<ul>
|
|
||||||
<li>access a webcam or microphone</li>
|
|
||||||
<li>access an API served over HTTPS</li>
|
|
||||||
</ul>
|
|
||||||
<p>Choose HTTP if you need to:</p>
|
|
||||||
<ul>
|
|
||||||
<li>access an API served over HTTP</li>
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
export default HTTPSModal;
|
|
|
@ -92,7 +92,7 @@ class Preferences extends React.Component {
|
||||||
const beep = new Audio(beepUrl);
|
const beep = new Audio(beepUrl);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<section className="preferences" title="preference-menu">
|
<section className="preferences">
|
||||||
<Helmet>
|
<Helmet>
|
||||||
<title>p5.js Web Editor | Preferences</title>
|
<title>p5.js Web Editor | Preferences</title>
|
||||||
</Helmet>
|
</Helmet>
|
||||||
|
|
|
@ -360,7 +360,7 @@ class PreviewFrame extends React.Component {
|
||||||
aria-label="sketch output"
|
aria-label="sketch output"
|
||||||
role="main"
|
role="main"
|
||||||
frameBorder="0"
|
frameBorder="0"
|
||||||
title="sketch output"
|
title="sketch preview"
|
||||||
ref={(element) => { this.iframeElement = element; }}
|
ref={(element) => { this.iframeElement = element; }}
|
||||||
sandbox="allow-scripts allow-pointer-lock allow-same-origin allow-popups allow-forms allow-modals"
|
sandbox="allow-scripts allow-pointer-lock allow-same-origin allow-popups allow-forms allow-modals"
|
||||||
/>
|
/>
|
||||||
|
|
|
@ -15,7 +15,6 @@ import NewFolderModal from '../components/NewFolderModal';
|
||||||
import ShareModal from '../components/ShareModal';
|
import ShareModal from '../components/ShareModal';
|
||||||
import KeyboardShortcutModal from '../components/KeyboardShortcutModal';
|
import KeyboardShortcutModal from '../components/KeyboardShortcutModal';
|
||||||
import ErrorModal from '../components/ErrorModal';
|
import ErrorModal from '../components/ErrorModal';
|
||||||
import HTTPSModal from '../components/HTTPSModal';
|
|
||||||
import Nav from '../../../components/Nav';
|
import Nav from '../../../components/Nav';
|
||||||
import Console from '../components/Console';
|
import Console from '../components/Console';
|
||||||
import Toast from '../components/Toast';
|
import Toast from '../components/Toast';
|
||||||
|
@ -197,7 +196,6 @@ class IDEView extends React.Component {
|
||||||
<Toolbar />
|
<Toolbar />
|
||||||
{this.props.ide.preferencesIsVisible &&
|
{this.props.ide.preferencesIsVisible &&
|
||||||
<Overlay
|
<Overlay
|
||||||
title="Settings"
|
|
||||||
ariaLabel="settings"
|
ariaLabel="settings"
|
||||||
closeOverlay={this.props.closePreferences}
|
closeOverlay={this.props.closePreferences}
|
||||||
>
|
>
|
||||||
|
@ -397,7 +395,6 @@ class IDEView extends React.Component {
|
||||||
{ this.props.location.pathname === '/about' &&
|
{ this.props.location.pathname === '/about' &&
|
||||||
<Overlay
|
<Overlay
|
||||||
previousPath={this.props.ide.previousPath}
|
previousPath={this.props.ide.previousPath}
|
||||||
title="Welcome"
|
|
||||||
ariaLabel="about"
|
ariaLabel="about"
|
||||||
>
|
>
|
||||||
<About previousPath={this.props.ide.previousPath} />
|
<About previousPath={this.props.ide.previousPath} />
|
||||||
|
@ -406,7 +403,6 @@ class IDEView extends React.Component {
|
||||||
{ this.props.location.pathname === '/feedback' &&
|
{ this.props.location.pathname === '/feedback' &&
|
||||||
<Overlay
|
<Overlay
|
||||||
previousPath={this.props.ide.previousPath}
|
previousPath={this.props.ide.previousPath}
|
||||||
title="Submit Feedback"
|
|
||||||
ariaLabel="submit-feedback"
|
ariaLabel="submit-feedback"
|
||||||
>
|
>
|
||||||
<Feedback previousPath={this.props.ide.previousPath} />
|
<Feedback previousPath={this.props.ide.previousPath} />
|
||||||
|
@ -414,7 +410,6 @@ class IDEView extends React.Component {
|
||||||
}
|
}
|
||||||
{ this.props.ide.shareModalVisible &&
|
{ this.props.ide.shareModalVisible &&
|
||||||
<Overlay
|
<Overlay
|
||||||
title="Share This Sketch"
|
|
||||||
ariaLabel="share"
|
ariaLabel="share"
|
||||||
closeOverlay={this.props.closeShareModal}
|
closeOverlay={this.props.closeShareModal}
|
||||||
>
|
>
|
||||||
|
@ -427,7 +422,6 @@ class IDEView extends React.Component {
|
||||||
}
|
}
|
||||||
{ this.props.ide.keyboardShortcutVisible &&
|
{ this.props.ide.keyboardShortcutVisible &&
|
||||||
<Overlay
|
<Overlay
|
||||||
title="Keyboard Shortcuts"
|
|
||||||
ariaLabel="keyboard shortcuts"
|
ariaLabel="keyboard shortcuts"
|
||||||
closeOverlay={this.props.closeKeyboardShortcutModal}
|
closeOverlay={this.props.closeKeyboardShortcutModal}
|
||||||
>
|
>
|
||||||
|
@ -436,7 +430,6 @@ class IDEView extends React.Component {
|
||||||
}
|
}
|
||||||
{ this.props.ide.errorType &&
|
{ this.props.ide.errorType &&
|
||||||
<Overlay
|
<Overlay
|
||||||
title="Error"
|
|
||||||
ariaLabel="error"
|
ariaLabel="error"
|
||||||
closeOverlay={this.props.hideErrorModal}
|
closeOverlay={this.props.hideErrorModal}
|
||||||
>
|
>
|
||||||
|
@ -446,14 +439,6 @@ class IDEView extends React.Component {
|
||||||
/>
|
/>
|
||||||
</Overlay>
|
</Overlay>
|
||||||
}
|
}
|
||||||
{ this.props.ide.helpType &&
|
|
||||||
<Overlay
|
|
||||||
title="Serve over HTTPS"
|
|
||||||
closeOverlay={this.props.hideHelpModal}
|
|
||||||
>
|
|
||||||
<HTTPSModal />
|
|
||||||
</Overlay>
|
|
||||||
}
|
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -499,7 +484,6 @@ IDEView.propTypes = {
|
||||||
previousPath: PropTypes.string.isRequired,
|
previousPath: PropTypes.string.isRequired,
|
||||||
justOpenedProject: PropTypes.bool.isRequired,
|
justOpenedProject: PropTypes.bool.isRequired,
|
||||||
errorType: PropTypes.string,
|
errorType: PropTypes.string,
|
||||||
helpType: PropTypes.string,
|
|
||||||
runtimeErrorWarningVisible: PropTypes.bool.isRequired,
|
runtimeErrorWarningVisible: PropTypes.bool.isRequired,
|
||||||
}).isRequired,
|
}).isRequired,
|
||||||
stopSketch: PropTypes.func.isRequired,
|
stopSketch: PropTypes.func.isRequired,
|
||||||
|
@ -600,7 +584,6 @@ IDEView.propTypes = {
|
||||||
hideErrorModal: PropTypes.func.isRequired,
|
hideErrorModal: PropTypes.func.isRequired,
|
||||||
clearPersistedState: PropTypes.func.isRequired,
|
clearPersistedState: PropTypes.func.isRequired,
|
||||||
persistState: PropTypes.func.isRequired,
|
persistState: PropTypes.func.isRequired,
|
||||||
hideHelpModal: PropTypes.func.isRequired,
|
|
||||||
showRuntimeErrorWarning: PropTypes.func.isRequired,
|
showRuntimeErrorWarning: PropTypes.func.isRequired,
|
||||||
hideRuntimeErrorWarning: PropTypes.func.isRequired,
|
hideRuntimeErrorWarning: PropTypes.func.isRequired,
|
||||||
startSketch: PropTypes.func.isRequired,
|
startSketch: PropTypes.func.isRequired,
|
||||||
|
|
|
@ -102,10 +102,6 @@ const ide = (state = initialState, action) => {
|
||||||
return Object.assign({}, state, { errorType: action.modalType });
|
return Object.assign({}, state, { errorType: action.modalType });
|
||||||
case ActionTypes.HIDE_ERROR_MODAL:
|
case ActionTypes.HIDE_ERROR_MODAL:
|
||||||
return Object.assign({}, state, { errorType: undefined });
|
return Object.assign({}, state, { errorType: undefined });
|
||||||
case ActionTypes.SHOW_HELP_MODAL:
|
|
||||||
return Object.assign({}, state, { helpType: action.helpType });
|
|
||||||
case ActionTypes.HIDE_HELP_MODAL:
|
|
||||||
return Object.assign({}, state, { helpType: undefined });
|
|
||||||
case ActionTypes.HIDE_RUNTIME_ERROR_WARNING:
|
case ActionTypes.HIDE_RUNTIME_ERROR_WARNING:
|
||||||
return Object.assign({}, state, { runtimeErrorWarningVisible: false });
|
return Object.assign({}, state, { runtimeErrorWarningVisible: false });
|
||||||
case ActionTypes.SHOW_RUNTIME_ERROR_WARNING:
|
case ActionTypes.SHOW_RUNTIME_ERROR_WARNING:
|
||||||
|
|
Loading…
Reference in a new issue