update file system file mock data to match new model
This commit is contained in:
@@ -9,39 +9,39 @@ export type UmbMockPartialViewModelHack = PartialViewResponseModel &
|
||||
FileSystemTreeItemPresentationModel &
|
||||
PartialViewItemResponseModel;
|
||||
|
||||
export interface UmbMockPartialViewModel extends Omit<UmbMockPartialViewModelHack, 'type' | 'icon'> {
|
||||
parentPath: string | null;
|
||||
}
|
||||
export interface UmbMockPartialViewModel extends Omit<UmbMockPartialViewModelHack, 'type' | 'icon'> {}
|
||||
|
||||
export const data: Array<UmbMockPartialViewModel> = [
|
||||
{
|
||||
name: 'blockgrid',
|
||||
path: 'blockgrid',
|
||||
parentPath: null,
|
||||
path: '/blockgrid',
|
||||
parent: null,
|
||||
isFolder: true,
|
||||
hasChildren: true,
|
||||
content: '',
|
||||
},
|
||||
{
|
||||
name: 'blocklist',
|
||||
path: 'blocklist',
|
||||
parentPath: null,
|
||||
path: '/blocklist',
|
||||
parent: null,
|
||||
isFolder: true,
|
||||
hasChildren: true,
|
||||
content: '',
|
||||
},
|
||||
{
|
||||
name: 'grid',
|
||||
path: 'grid',
|
||||
parentPath: null,
|
||||
path: '/grid',
|
||||
parent: null,
|
||||
isFolder: true,
|
||||
hasChildren: true,
|
||||
content: '',
|
||||
},
|
||||
{
|
||||
name: 'area.cshtml',
|
||||
path: 'blockgrid/area.cshtml',
|
||||
parentPath: 'blockgrid',
|
||||
path: '/blockgrid/area.cshtml',
|
||||
parent: {
|
||||
path: '/blockgrid',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `@using Umbraco.Extensions
|
||||
@@ -58,16 +58,20 @@ export const data: Array<UmbMockPartialViewModel> = [
|
||||
},
|
||||
{
|
||||
name: 'items.cshtml',
|
||||
path: 'blockgrid/items.cshtml',
|
||||
parentPath: 'blockgrid',
|
||||
path: '/blockgrid/items.cshtml',
|
||||
parent: {
|
||||
path: '/blockgrid',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: '@inherits Umbraco.Cms.Web.Common.Views.UmbracoViewPage',
|
||||
},
|
||||
{
|
||||
name: 'default.cshtml',
|
||||
path: 'blocklist/default.cshtml',
|
||||
parentPath: 'blocklist',
|
||||
path: '/blocklist/default.cshtml',
|
||||
parent: {
|
||||
path: '/blocklist',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `@using Umbraco.Extensions
|
||||
@@ -85,8 +89,10 @@ export const data: Array<UmbMockPartialViewModel> = [
|
||||
},
|
||||
{
|
||||
name: 'embed.cshtml',
|
||||
path: 'grid/embed.cshtm',
|
||||
parentPath: 'grid',
|
||||
path: '/grid/embed.cshtm',
|
||||
parent: {
|
||||
path: '/grid',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `@inherits Umbraco.Cms.Web.Common.Views.UmbracoViewPage<dynamic>
|
||||
@@ -104,8 +110,10 @@ export const data: Array<UmbMockPartialViewModel> = [
|
||||
},
|
||||
{
|
||||
name: 'default.cshtml',
|
||||
path: 'grid/default.cshtml',
|
||||
parentPath: 'grid',
|
||||
path: '/grid/default.cshtml',
|
||||
parent: {
|
||||
path: '/grid',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: '@inherits Umbraco.Cms.Web.Common.Views.UmbracoViewPage',
|
||||
|
||||
@@ -8,39 +8,39 @@ export type UmbMockScriptModelHack = ScriptResponseModel &
|
||||
FileSystemTreeItemPresentationModel &
|
||||
ScriptItemResponseModel;
|
||||
|
||||
export interface UmbMockScriptModel extends Omit<UmbMockScriptModelHack, 'type' | 'icon'> {
|
||||
parentPath: string | null;
|
||||
}
|
||||
export interface UmbMockScriptModel extends Omit<UmbMockScriptModelHack, 'type' | 'icon'> {}
|
||||
|
||||
export const data: Array<UmbMockScriptModel> = [
|
||||
{
|
||||
name: 'some-folder',
|
||||
path: 'some-folder',
|
||||
parentPath: null,
|
||||
path: '/some-folder',
|
||||
parent: null,
|
||||
isFolder: true,
|
||||
hasChildren: true,
|
||||
content: '',
|
||||
},
|
||||
{
|
||||
name: 'another-folder',
|
||||
path: 'another-folder',
|
||||
parentPath: null,
|
||||
path: '/another-folder',
|
||||
parent: null,
|
||||
isFolder: true,
|
||||
hasChildren: true,
|
||||
content: '',
|
||||
},
|
||||
{
|
||||
name: 'very important folder',
|
||||
path: 'very important folder',
|
||||
parentPath: null,
|
||||
path: '/very important folder',
|
||||
parent: null,
|
||||
isFolder: true,
|
||||
hasChildren: true,
|
||||
content: '',
|
||||
},
|
||||
{
|
||||
name: 'ugly script.js',
|
||||
path: 'some-folder/ugly script.js',
|
||||
parentPath: 'some-folder',
|
||||
path: '/some-folder/ugly script.js',
|
||||
parent: {
|
||||
path: '/some-folder',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `function makeid(length) {
|
||||
@@ -57,8 +57,10 @@ export const data: Array<UmbMockScriptModel> = [
|
||||
},
|
||||
{
|
||||
name: 'nice script.js',
|
||||
path: 'some-folder/nice script.js',
|
||||
parentPath: 'some-folder',
|
||||
path: '/some-folder/nice script.js',
|
||||
parent: {
|
||||
path: '/some-folder',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `var items = {
|
||||
@@ -72,8 +74,10 @@ export const data: Array<UmbMockScriptModel> = [
|
||||
},
|
||||
{
|
||||
name: 'only bugs.js',
|
||||
path: 'another-folder/only bugs.js',
|
||||
parentPath: 'another-folder',
|
||||
path: '/another-folder/only bugs.js',
|
||||
parent: {
|
||||
path: '/another-folder',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `var my_arr = [4, '', 0, 10, 7, '', false, 10];
|
||||
@@ -84,8 +88,10 @@ export const data: Array<UmbMockScriptModel> = [
|
||||
},
|
||||
{
|
||||
name: 'no bugs at all.js',
|
||||
path: 'very important folder/no bugs at all.js',
|
||||
parentPath: 'very important folder',
|
||||
path: '/very important folder/no bugs at all.js',
|
||||
parent: {
|
||||
path: '/very important folder',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `const date_str = "07/20/2021";
|
||||
@@ -99,8 +105,10 @@ export const data: Array<UmbMockScriptModel> = [
|
||||
},
|
||||
{
|
||||
name: 'nope.js',
|
||||
path: 'very important folder/nope.js',
|
||||
parentPath: 'very important folder',
|
||||
path: '/very important folder/nope.js',
|
||||
parent: {
|
||||
path: '/very important folder',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `// Define an object
|
||||
@@ -117,8 +125,10 @@ export const data: Array<UmbMockScriptModel> = [
|
||||
},
|
||||
{
|
||||
name: 'file-with-dash.js',
|
||||
path: 'very important folder/file-with-dash.js',
|
||||
parentPath: 'very important folder',
|
||||
path: '/very important folder/file-with-dash.js',
|
||||
parent: {
|
||||
path: '/very important folder',
|
||||
},
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `alert('hello file with dash');`,
|
||||
|
||||
@@ -8,15 +8,13 @@ export type UmbMockStylesheetModelHack = StylesheetResponseModel &
|
||||
FileSystemTreeItemPresentationModel &
|
||||
StylesheetItemResponseModel;
|
||||
|
||||
export interface UmbMockStylesheetModel extends Omit<UmbMockStylesheetModelHack, 'type' | 'icon'> {
|
||||
parentPath: string | null;
|
||||
}
|
||||
export interface UmbMockStylesheetModel extends Omit<UmbMockStylesheetModelHack, 'type' | 'icon'> {}
|
||||
|
||||
export const data: Array<UmbMockStylesheetModel> = [
|
||||
{
|
||||
name: 'Stylesheet File 1.css',
|
||||
path: 'Stylesheet File 1.css',
|
||||
parentPath: null,
|
||||
path: '/Stylesheet File 1.css',
|
||||
parent: null,
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `
|
||||
@@ -43,8 +41,8 @@ h1 {
|
||||
},
|
||||
{
|
||||
name: 'Stylesheet File 2.css',
|
||||
path: 'Stylesheet File 2.css',
|
||||
parentPath: null,
|
||||
path: '/Stylesheet File 2.css',
|
||||
parent: null,
|
||||
isFolder: false,
|
||||
hasChildren: false,
|
||||
content: `
|
||||
@@ -70,16 +68,18 @@ h1 {
|
||||
},
|
||||
{
|
||||
name: 'Folder 1',
|
||||
path: 'Folder 1',
|
||||
parentPath: null,
|
||||
path: '/Folder 1',
|
||||
parent: null,
|
||||
isFolder: true,
|
||||
hasChildren: true,
|
||||
content: '',
|
||||
},
|
||||
{
|
||||
name: 'Stylesheet File 3.css',
|
||||
path: 'Folder 1/Stylesheet File 3.css',
|
||||
parentPath: 'Folder 1',
|
||||
path: '/Folder 1/Stylesheet File 3.css',
|
||||
parent: {
|
||||
path: '/Folder 1',
|
||||
},
|
||||
hasChildren: false,
|
||||
isFolder: false,
|
||||
content: `h1 {
|
||||
|
||||
Reference in New Issue
Block a user