Commit bc48b173 authored by Enrique Alcántara's avatar Enrique Alcántara

Merge branch 'rich-content-editor-services-directory-update' into 'master'

Move editor_service to services dir

See merge request gitlab-org/gitlab!35032
parents 0e7e33e0 1c2d4464
import { __ } from '~/locale'; import { __ } from '~/locale';
import { generateToolbarItem } from './editor_service'; import { generateToolbarItem } from './services/editor_service';
import buildCustomHTMLRenderer from './services/build_custom_renderer'; import buildCustomHTMLRenderer from './services/build_custom_renderer';
export const CUSTOM_EVENTS = { export const CUSTOM_EVENTS = {
......
...@@ -16,7 +16,7 @@ import { ...@@ -16,7 +16,7 @@ import {
removeCustomEventListener, removeCustomEventListener,
addImage, addImage,
getMarkdown, getMarkdown,
} from './editor_service'; } from './services/editor_service';
export default { export default {
components: { components: {
......
import Vue from 'vue'; import Vue from 'vue';
import ToolbarItem from './toolbar_item.vue'; import ToolbarItem from '../toolbar_item.vue';
const buildWrapper = propsData => { const buildWrapper = propsData => {
const instance = new Vue({ const instance = new Vue({
......
...@@ -4,7 +4,7 @@ import { ...@@ -4,7 +4,7 @@ import {
removeCustomEventListener, removeCustomEventListener,
addImage, addImage,
getMarkdown, getMarkdown,
} from '~/vue_shared/components/rich_content_editor/editor_service'; } from '~/vue_shared/components/rich_content_editor/services/editor_service';
describe('Editor Service', () => { describe('Editor Service', () => {
const mockInstance = { const mockInstance = {
......
...@@ -13,10 +13,10 @@ import { ...@@ -13,10 +13,10 @@ import {
addCustomEventListener, addCustomEventListener,
removeCustomEventListener, removeCustomEventListener,
addImage, addImage,
} from '~/vue_shared/components/rich_content_editor/editor_service'; } from '~/vue_shared/components/rich_content_editor/services/editor_service';
jest.mock('~/vue_shared/components/rich_content_editor/editor_service', () => ({ jest.mock('~/vue_shared/components/rich_content_editor/services/editor_service', () => ({
...jest.requireActual('~/vue_shared/components/rich_content_editor/editor_service'), ...jest.requireActual('~/vue_shared/components/rich_content_editor/services/editor_service'),
addCustomEventListener: jest.fn(), addCustomEventListener: jest.fn(),
removeCustomEventListener: jest.fn(), removeCustomEventListener: jest.fn(),
addImage: jest.fn(), addImage: jest.fn(),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment