Sharing global styles
This commit is contained in:
@@ -3,7 +3,7 @@ import React from 'react';
|
||||
import { observer } from 'mobx-react';
|
||||
import Flex from 'components/Flex';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
type Props = {
|
||||
children: React.Element<*>,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import { darken, lighten } from 'polished';
|
||||
|
||||
const RealButton = styled.button`
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React from 'react';
|
||||
import moment from 'moment';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import Flex from 'components/Flex';
|
||||
import Tooltip from 'components/Tooltip';
|
||||
import Document from 'models/Document';
|
||||
|
||||
@@ -4,7 +4,7 @@ import { observer } from 'mobx-react';
|
||||
import { Link } from 'react-router-dom';
|
||||
import Document from 'models/Document';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import StarredIcon from 'components/Icon/StarredIcon';
|
||||
import PublishingInfo from './components/PublishingInfo';
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React, { Component } from 'react';
|
||||
import moment from 'moment';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import Collection from 'models/Collection';
|
||||
import Document from 'models/Document';
|
||||
import Flex from 'components/Flex';
|
||||
|
||||
@@ -6,8 +6,8 @@ import { observer } from 'mobx-react';
|
||||
import styled from 'styled-components';
|
||||
import Portal from 'react-portal';
|
||||
import Flex from 'components/Flex';
|
||||
import { color } from 'styles/constants';
|
||||
import { fadeAndScaleIn } from 'styles/animations';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import { fadeAndScaleIn } from 'shared/styles/animations';
|
||||
|
||||
type Props = {
|
||||
label: React.Element<*>,
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import Flex from 'components/Flex';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
const DropdownMenuItem = ({
|
||||
onClick,
|
||||
|
||||
@@ -6,7 +6,7 @@ import Portal from 'react-portal';
|
||||
import { observable } from 'mobx';
|
||||
import { observer } from 'mobx-react';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import PlusIcon from 'components/Icon/PlusIcon';
|
||||
import BlockMenu from 'menus/BlockMenu';
|
||||
import type { State } from '../types';
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import CopyButton from './CopyButton';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import type { Props } from '../types';
|
||||
|
||||
export default function Code({ children, node, readOnly, attributes }: Props) {
|
||||
|
||||
@@ -3,7 +3,7 @@ import React, { Component } from 'react';
|
||||
import { observable } from 'mobx';
|
||||
import { observer } from 'mobx-react';
|
||||
import { List } from 'immutable';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import headingToSlug from '../headingToSlug';
|
||||
import type { State, Block } from '../types';
|
||||
import styled from 'styled-components';
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React, { Component } from 'react';
|
||||
import { observable } from 'mobx';
|
||||
import { observer } from 'mobx-react';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import styled from 'styled-components';
|
||||
import CopyToClipboard from 'components/CopyToClipboard';
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import type { Props } from '../types';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
function HorizontalRule(props: Props) {
|
||||
const { state, node } = props;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React, { Component } from 'react';
|
||||
import styled from 'styled-components';
|
||||
import type { Props } from '../types';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
class Image extends Component {
|
||||
props: Props;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// @flow
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
const InlineCode = styled.code`
|
||||
padding: .25em;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @flow
|
||||
import React, { Component } from 'react';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import type { Props } from '../types';
|
||||
|
||||
export default class TodoItem extends Component {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import { fontWeight, color } from 'styles/constants';
|
||||
import { fontWeight, color } from 'shared/styles/constants';
|
||||
import Document from 'models/Document';
|
||||
import NextIcon from 'components/Icon/NextIcon';
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
type Props = {
|
||||
children: string,
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// @flow
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
const HelpText = styled.p`
|
||||
margin-top: 0;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
export type Props = {
|
||||
className?: string,
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import Flex from 'components/Flex';
|
||||
import { size, color } from 'styles/constants';
|
||||
import { size, color } from 'shared/styles/constants';
|
||||
|
||||
const RealTextarea = styled.textarea`
|
||||
border: 0;
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// @flow
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
|
||||
const Key = styled.kbd`
|
||||
display: inline-block;
|
||||
|
||||
@@ -3,7 +3,7 @@ import React from 'react';
|
||||
import { observer } from 'mobx-react';
|
||||
import Flex from 'components/Flex';
|
||||
import styled from 'styled-components';
|
||||
import { size } from 'styles/constants';
|
||||
import { size } from 'shared/styles/constants';
|
||||
|
||||
type Props = {
|
||||
label: React.Element<*> | string,
|
||||
|
||||
@@ -6,7 +6,7 @@ import styled from 'styled-components';
|
||||
import { observer, inject } from 'mobx-react';
|
||||
import keydown from 'react-keydown';
|
||||
import Flex from 'components/Flex';
|
||||
import { color, layout } from 'styles/constants';
|
||||
import { color, layout } from 'shared/styles/constants';
|
||||
import { documentEditUrl, homeUrl, searchUrl } from 'utils/routeHelpers';
|
||||
|
||||
import Avatar from 'components/Avatar';
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// @flow
|
||||
import React from 'react';
|
||||
import styled from 'styled-components';
|
||||
import { color } from 'styles/constants';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import type { User, Team } from 'types';
|
||||
import Flex from 'components/Flex';
|
||||
|
||||
@@ -28,7 +28,6 @@ const UserName = styled.div`
|
||||
`;
|
||||
|
||||
const TeamName = styled.div`
|
||||
font-family: 'Atlas Grotesk';
|
||||
font-weight: bold;
|
||||
color: ${color.text};
|
||||
text-decoration: none;
|
||||
|
||||
@@ -4,7 +4,7 @@ import { observable } from 'mobx';
|
||||
import { observer, inject } from 'mobx-react';
|
||||
import Flex from 'components/Flex';
|
||||
import styled from 'styled-components';
|
||||
import { color, fontWeight } from 'styles/constants';
|
||||
import { color, fontWeight } from 'shared/styles/constants';
|
||||
|
||||
import SidebarLink from './SidebarLink';
|
||||
import DropToImport from 'components/DropToImport';
|
||||
|
||||
@@ -3,7 +3,7 @@ import React, { Component } from 'react';
|
||||
import { observable, action } from 'mobx';
|
||||
import { observer } from 'mobx-react';
|
||||
import { NavLink } from 'react-router-dom';
|
||||
import { color, fontWeight } from 'styles/constants';
|
||||
import { color, fontWeight } from 'shared/styles/constants';
|
||||
import styled from 'styled-components';
|
||||
import Flex from 'components/Flex';
|
||||
import CollapsedIcon from 'components/Icon/CollapsedIcon';
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
import React from 'react';
|
||||
import ReactCSSTransitionGroup from 'react-addons-css-transition-group';
|
||||
import styled from 'styled-components';
|
||||
import { pulsate } from 'styles/animations';
|
||||
import { color } from 'styles/constants';
|
||||
import { pulsate } from 'shared/styles/animations';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import Flex from 'components/Flex';
|
||||
|
||||
import { randomInteger } from 'utils/random';
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
// @flow
|
||||
import React, { Component } from 'react';
|
||||
import styled from 'styled-components';
|
||||
import { pulsate } from 'styles/animations';
|
||||
import { color } from 'styles/constants';
|
||||
import { pulsate } from 'shared/styles/animations';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import { randomInteger } from 'utils/random';
|
||||
import Flex from 'components/Flex';
|
||||
|
||||
|
||||
@@ -3,8 +3,8 @@ import React from 'react';
|
||||
import { observer } from 'mobx-react';
|
||||
import styled from 'styled-components';
|
||||
import ReactModal from 'react-modal';
|
||||
import { color } from 'styles/constants';
|
||||
import { fadeAndScaleIn } from 'styles/animations';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import { fadeAndScaleIn } from 'shared/styles/animations';
|
||||
import CloseIcon from 'components/Icon/CloseIcon';
|
||||
import Flex from 'components/Flex';
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
import React, { Component } from 'react';
|
||||
import { inject, observer } from 'mobx-react';
|
||||
import styled from 'styled-components';
|
||||
import { layout } from 'styles/constants';
|
||||
import { layout } from 'shared/styles/constants';
|
||||
import Toast from './components/Toast';
|
||||
|
||||
@observer class Toasts extends Component {
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
import React, { Component } from 'react';
|
||||
import styled from 'styled-components';
|
||||
import { darken } from 'polished';
|
||||
import { color } from 'styles/constants';
|
||||
import { fadeAndScaleIn } from 'styles/animations';
|
||||
import { color } from 'shared/styles/constants';
|
||||
import { fadeAndScaleIn } from 'shared/styles/animations';
|
||||
|
||||
type Props = {
|
||||
onRequestClose: () => void,
|
||||
|
||||
Reference in New Issue
Block a user