Add vendor to JS namespace

This commit is contained in:
Toby Zerner 2015-10-03 16:48:37 +09:30
parent 5c46e03750
commit 9bb30a1cc3
13 changed files with 28 additions and 28 deletions

View File

@ -5,7 +5,7 @@ gulp({
'bower_components/html.sortable/dist/html.sortable.js'
],
modules: {
'tags': [
'flarum/tags': [
'../lib/**/*.js',
'src/**/*.js'
]

View File

@ -2,7 +2,7 @@ var gulp = require('flarum-gulp');
gulp({
modules: {
'tags': [
'flarum/tags': [
'../lib/**/*.js',
'src/**/*.js'
]

View File

@ -2,8 +2,8 @@ import { extend, override } from 'flarum/extend';
import IndexPage from 'flarum/components/IndexPage';
import DiscussionComposer from 'flarum/components/DiscussionComposer';
import TagDiscussionModal from 'tags/components/TagDiscussionModal';
import tagsLabel from 'tags/helpers/tagsLabel';
import TagDiscussionModal from 'flarum/tags/components/TagDiscussionModal';
import tagsLabel from 'flarum/tags/helpers/tagsLabel';
export default function() {
extend(IndexPage.prototype, 'composeNewDiscussion', function(promise) {

View File

@ -2,7 +2,7 @@ import { extend } from 'flarum/extend';
import DiscussionControls from 'flarum/utils/DiscussionControls';
import Button from 'flarum/components/Button';
import TagDiscussionModal from 'tags/components/TagDiscussionModal';
import TagDiscussionModal from 'flarum/tags/components/TagDiscussionModal';
export default function() {
// Add a control allowing the discussion to be moved to another category.

View File

@ -2,7 +2,7 @@ import { extend, override } from 'flarum/extend';
import IndexPage from 'flarum/components/IndexPage';
import DiscussionList from 'flarum/components/DiscussionList';
import TagHero from 'tags/components/TagHero';
import TagHero from 'flarum/tags/components/TagHero';
export default function() {
IndexPage.prototype.currentTag = function() {

View File

@ -3,8 +3,8 @@ import DiscussionListItem from 'flarum/components/DiscussionListItem';
import DiscussionPage from 'flarum/components/DiscussionPage';
import DiscussionHero from 'flarum/components/DiscussionHero';
import tagsLabel from 'tags/helpers/tagsLabel';
import sortTags from 'tags/utils/sortTags';
import tagsLabel from 'flarum/tags/helpers/tagsLabel';
import sortTags from 'flarum/tags/utils/sortTags';
export default function() {
// Add tag labels to each discussion in the discussion list.

View File

@ -3,9 +3,9 @@ import IndexPage from 'flarum/components/IndexPage';
import Separator from 'flarum/components/Separator';
import LinkButton from 'flarum/components/LinkButton';
import TagLinkButton from 'tags/components/TagLinkButton';
import TagsPage from 'tags/components/TagsPage';
import sortTags from 'tags/utils/sortTags';
import TagLinkButton from 'flarum/tags/components/TagLinkButton';
import TagsPage from 'flarum/tags/components/TagsPage';
import sortTags from 'flarum/tags/utils/sortTags';
export default function() {
// Add a link to the tags page, as well as a list of all the tags,

View File

@ -1,6 +1,6 @@
import EventPost from 'flarum/components/EventPost';
import punctuate from 'flarum/helpers/punctuate';
import tagsLabel from 'tags/helpers/tagsLabel';
import tagsLabel from 'flarum/tags/helpers/tagsLabel';
export default class DiscussionTaggedPost extends EventPost {
icon() {

View File

@ -5,9 +5,9 @@ import highlight from 'flarum/helpers/highlight';
import classList from 'flarum/utils/classList';
import extractText from 'flarum/utils/extractText';
import tagLabel from 'tags/helpers/tagLabel';
import tagIcon from 'tags/helpers/tagIcon';
import sortTags from 'tags/utils/sortTags';
import tagLabel from 'flarum/tags/helpers/tagLabel';
import tagIcon from 'flarum/tags/helpers/tagIcon';
import sortTags from 'flarum/tags/utils/sortTags';
export default class TagDiscussionModal extends Modal {
constructor(...args) {

View File

@ -1,5 +1,5 @@
import LinkButton from 'flarum/components/LinkButton';
import tagIcon from 'tags/helpers/tagIcon';
import tagIcon from 'flarum/tags/helpers/tagIcon';
export default class TagLinkButton extends LinkButton {
view() {

View File

@ -3,8 +3,8 @@ import IndexPage from 'flarum/components/IndexPage';
import listItems from 'flarum/helpers/listItems';
import humanTime from 'flarum/helpers/humanTime';
import tagLabel from 'tags/helpers/tagLabel';
import sortTags from 'tags/utils/sortTags';
import tagLabel from 'flarum/tags/helpers/tagLabel';
import sortTags from 'flarum/tags/utils/sortTags';
export default class TagsPage extends Component {
constructor(...args) {

View File

@ -2,15 +2,15 @@ import Model from 'flarum/Model';
import Discussion from 'flarum/models/Discussion';
import IndexPage from 'flarum/components/IndexPage';
import Tag from 'tags/models/Tag';
import TagsPage from 'tags/components/TagsPage';
import DiscussionTaggedPost from 'tags/components/DiscussionTaggedPost';
import Tag from 'flarum/tags/models/Tag';
import TagsPage from 'flarum/tags/components/TagsPage';
import DiscussionTaggedPost from 'flarum/tags/components/DiscussionTaggedPost';
import addTagList from 'tags/addTagList';
import addTagFilter from 'tags/addTagFilter';
import addTagLabels from 'tags/addTagLabels';
import addTagControl from 'tags/addTagControl';
import addTagComposer from 'tags/addTagComposer';
import addTagList from 'flarum/tags/addTagList';
import addTagFilter from 'flarum/tags/addTagFilter';
import addTagLabels from 'flarum/tags/addTagLabels';
import addTagControl from 'flarum/tags/addTagControl';
import addTagComposer from 'flarum/tags/addTagComposer';
app.initializers.add('tags', function(app) {
app.routes.tags = {path: '/tags', component: TagsPage.component()};

View File

@ -1,6 +1,6 @@
import extract from 'flarum/utils/extract';
import tagLabel from 'tags/helpers/tagLabel';
import sortTags from 'tags/utils/sortTags';
import tagLabel from 'flarum/tags/helpers/tagLabel';
import sortTags from 'flarum/tags/utils/sortTags';
export default function tagsLabel(tags, attrs = {}) {
const children = [];