diff --git a/src/components/anchors.js b/src/components/anchors/anchors.js similarity index 98% rename from src/components/anchors.js rename to src/components/anchors/anchors.js index e620387..e85f495 100644 --- a/src/components/anchors.js +++ b/src/components/anchors/anchors.js @@ -1,7 +1,7 @@ import React from 'react' import PropTypes from 'prop-types' -import SVGs from '../svgs' +import SVGs from '../../svgs' export default class Anchors extends React.PureComponent { constructor(props) { diff --git a/src/components/parent-category.js b/src/components/category/category.js similarity index 61% rename from src/components/parent-category.js rename to src/components/category/category.js index 8b0f33f..7125760 100644 --- a/src/components/parent-category.js +++ b/src/components/category/category.js @@ -1,7 +1,11 @@ import React from 'react' -import data from '../data' -import { CategoryPropTypes, CategoryDefaultProps } from '../utils/shared-props' -import NimbleCategory from './category' +import data from '../../data' +import NimbleCategory from './nimble-category' + +import { + CategoryPropTypes, + CategoryDefaultProps, +} from '../../utils/shared-props' export default class Category extends React.Component { render() { diff --git a/src/components/category.js b/src/components/category/nimble-category.js similarity index 95% rename from src/components/category.js rename to src/components/category/nimble-category.js index f367953..91fd97f 100644 --- a/src/components/category.js +++ b/src/components/category/nimble-category.js @@ -1,10 +1,14 @@ import React from 'react' import PropTypes from 'prop-types' -import frequently from '../utils/frequently' -import { getData } from '../utils' -import { CategoryPropTypes, CategoryDefaultProps } from '../utils/shared-props' -import NimbleEmoji from './emoji' +import frequently from '../../utils/frequently' +import { getData } from '../../utils' +import { NimbleEmoji } from '..' + +import { + CategoryPropTypes, + CategoryDefaultProps, +} from '../../utils/shared-props' export default class NimbleCategory extends React.Component { constructor(props) { diff --git a/src/components/parent-emoji.js b/src/components/emoji/emoji.js similarity index 70% rename from src/components/parent-emoji.js rename to src/components/emoji/emoji.js index 661dcfb..153de82 100644 --- a/src/components/parent-emoji.js +++ b/src/components/emoji/emoji.js @@ -1,7 +1,9 @@ import React from 'react' -import data from '../data' -import { EmojiPropTypes, EmojiDefaultProps } from '../utils/shared-props' -import NimbleEmoji from './emoji' + +import data from '../../data' +import NimbleEmoji from './nimble-emoji' + +import { EmojiPropTypes, EmojiDefaultProps } from '../../utils/shared-props' const Emoji = (props) => { for (let k in Emoji.defaultProps) { diff --git a/src/components/emoji.js b/src/components/emoji/nimble-emoji.js similarity index 96% rename from src/components/emoji.js rename to src/components/emoji/nimble-emoji.js index c7457ed..ef3b3fc 100644 --- a/src/components/emoji.js +++ b/src/components/emoji/nimble-emoji.js @@ -1,8 +1,8 @@ import React from 'react' import PropTypes from 'prop-types' -import { getData, getSanitizedData, unifiedToNative } from '../utils' -import { EmojiPropTypes, EmojiDefaultProps } from '../utils/shared-props' +import { getData, getSanitizedData, unifiedToNative } from '../../utils' +import { EmojiPropTypes, EmojiDefaultProps } from '../../utils/shared-props' const SHEET_COLUMNS = 52 diff --git a/src/components/index.js b/src/components/index.js index ee40f44..6afd41f 100644 --- a/src/components/index.js +++ b/src/components/index.js @@ -1,12 +1,18 @@ -export { default as Anchors } from './anchors' -export { default as Category } from './parent-category' -export { default as Emoji } from './parent-emoji' -export { default as Picker } from './parent-picker' -export { default as Preview } from './parent-preview' -export { default as Search } from './parent-search' -export { default as Skins } from './skins' -export { default as NimbleCategory } from './category' -export { default as NimbleEmoji } from './emoji' -export { default as NimblePicker } from './picker' -export { default as NimblePreview } from './preview' -export { default as NimbleSearch } from './search' +export { default as Anchors } from './anchors/anchors' + +export { default as Category } from './category/category' +export { default as NimbleCategory } from './category/nimble-category' + +export { default as Emoji } from './emoji/emoji' +export { default as NimbleEmoji } from './emoji/nimble-emoji' + +export { default as Picker } from './picker/picker' +export { default as NimblePicker } from './picker/nimble-picker' + +export { default as Preview } from './preview/preview' +export { default as NimblePreview } from './preview/nimble-preview' + +export { default as Search } from './search/search' +export { default as NimbleSearch } from './search/nimble-search' + +export { default as Skins } from './skins/skins' diff --git a/src/components/picker.js b/src/components/picker/nimble-picker.js similarity index 98% rename from src/components/picker.js rename to src/components/picker/nimble-picker.js index b5492fa..1473a32 100644 --- a/src/components/picker.js +++ b/src/components/picker/nimble-picker.js @@ -1,14 +1,14 @@ -import '../vendor/raf-polyfill' +import '../../vendor/raf-polyfill' import React from 'react' import PropTypes from 'prop-types' -import store from '../utils/store' -import frequently from '../utils/frequently' -import { deepMerge, measureScrollbar } from '../utils' -import { PickerPropTypes, PickerDefaultProps } from '../utils/shared-props' +import store from '../../utils/store' +import frequently from '../../utils/frequently' +import { deepMerge, measureScrollbar } from '../../utils' +import { PickerPropTypes, PickerDefaultProps } from '../../utils/shared-props' -import { Anchors, NimbleCategory, NimblePreview, NimbleSearch } from '.' +import { Anchors, NimbleCategory, NimblePreview, NimbleSearch } from '..' const I18N = { search: 'Search', diff --git a/src/components/parent-picker.js b/src/components/picker/picker.js similarity index 59% rename from src/components/parent-picker.js rename to src/components/picker/picker.js index f3e4f97..09f3c9d 100644 --- a/src/components/parent-picker.js +++ b/src/components/picker/picker.js @@ -1,9 +1,9 @@ -import '../vendor/raf-polyfill' - import React from 'react' -import data from '../data' -import { PickerPropTypes, PickerDefaultProps } from '../utils/shared-props' -import NimblePicker from './picker' + +import data from '../../data' +import NimblePicker from './nimble-picker' + +import { PickerPropTypes, PickerDefaultProps } from '../../utils/shared-props' export default class Picker extends React.PureComponent { render() { diff --git a/src/components/preview.js b/src/components/preview/nimble-preview.js similarity index 94% rename from src/components/preview.js rename to src/components/preview/nimble-preview.js index e1ce27d..f45bb03 100644 --- a/src/components/preview.js +++ b/src/components/preview/nimble-preview.js @@ -1,9 +1,9 @@ import React from 'react' import PropTypes from 'prop-types' -import { PreviewPropTypes, PreviewDefaultProps } from '../utils/shared-props' -import { NimbleEmoji, Skins } from '.' -import { getData } from '../utils' +import { getData } from '../../utils' +import { NimbleEmoji, Skins } from '..' +import { PreviewPropTypes, PreviewDefaultProps } from '../../utils/shared-props' export default class NimblePreview extends React.PureComponent { constructor(props) { diff --git a/src/components/parent-preview.js b/src/components/preview/preview.js similarity index 62% rename from src/components/parent-preview.js rename to src/components/preview/preview.js index 544fe04..6edd37b 100644 --- a/src/components/parent-preview.js +++ b/src/components/preview/preview.js @@ -1,7 +1,9 @@ import React from 'react' -import data from '../data' -import { PreviewPropTypes, PreviewDefaultProps } from '../utils/shared-props' -import NimblePreview from './preview' + +import data from '../../data' +import NimblePreview from './nimble-preview' + +import { PreviewPropTypes, PreviewDefaultProps } from '../../utils/shared-props' export default class Preview extends React.PureComponent { render() { diff --git a/src/components/search.js b/src/components/search/nimble-search.js similarity index 90% rename from src/components/search.js rename to src/components/search/nimble-search.js index b31e1d0..ff63023 100644 --- a/src/components/search.js +++ b/src/components/search/nimble-search.js @@ -1,7 +1,8 @@ import React from 'react' import PropTypes from 'prop-types' -import NimbleEmojiIndex from '../utils/emoji-index' -import { SearchPropTypes, SearchDefaultProps } from '../utils/shared-props' + +import NimbleEmojiIndex from '../../utils/emoji-index' +import { SearchPropTypes, SearchDefaultProps } from '../../utils/shared-props' export default class NimbleSearch extends React.PureComponent { constructor(props) { diff --git a/src/components/parent-search.js b/src/components/search/search.js similarity index 62% rename from src/components/parent-search.js rename to src/components/search/search.js index d2c0ad8..9dc7cec 100644 --- a/src/components/parent-search.js +++ b/src/components/search/search.js @@ -1,7 +1,9 @@ import React from 'react' -import data from '../data' -import { SearchPropTypes, SearchDefaultProps } from '../utils/shared-props' -import NimbleSearch from './search' + +import data from '../../data' +import NimbleSearch from './nimble-search' + +import { SearchPropTypes, SearchDefaultProps } from '../../utils/shared-props' export default class Search extends React.PureComponent { render() { diff --git a/src/components/skins.js b/src/components/skins/skins.js similarity index 100% rename from src/components/skins.js rename to src/components/skins/skins.js