Skip to content

Commit

Permalink
[5306] Update to use experience builder instead of guest (#188)
Browse files Browse the repository at this point in the history
* Update to use experience builder instead of guest #5306

* Update version

* Build update
  • Loading branch information
jvega190 authored Jul 19, 2022
1 parent 6fbd513 commit ac66143
Show file tree
Hide file tree
Showing 25 changed files with 986 additions and 1,098 deletions.
2 changes: 1 addition & 1 deletion craftercms-plugin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ plugin:
version:
major: 2
minor: 0
patch: 30
patch: 31
description: |
Video Center webapp built with React atop CrafterCMS that is backed by YouTube, AWS Media Service, or Box.
website:
Expand Down
2 changes: 1 addition & 1 deletion sources/app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"dependencies": {
"@craftercms/classes": "^2.0.1",
"@craftercms/content": "^2.0.1",
"@craftercms/experience-builder": "^1.0.0-beta.2",
"@craftercms/experience-builder": "^1.0.0-rc.1",
"@craftercms/models": "^2.0.1",
"@craftercms/redux": "^2.0.1",
"@craftercms/search": "^2.0.1",
Expand Down
6 changes: 3 additions & 3 deletions sources/app/src/components/DynamicRoute.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import React, { useEffect, useState } from 'react';
import { urlTransform, getItem, parseDescriptor } from '@craftercms/content';
import { map } from 'rxjs/operators';
import { isAuthoring } from './utils';
import { Guest, ContentType } from '@craftercms/experience-builder/react';
import { ExperienceBuilder, ContentType } from '@craftercms/experience-builder/react';
import contentTypeMap from './contentTypeMap';

export default function DynamicRoute(props) {
Expand Down Expand Up @@ -53,7 +53,7 @@ export default function DynamicRoute(props) {
if (state === null) {
return <div></div>
} else {
return <Guest
return <ExperienceBuilder
isAuthoring={isAuthoring()}
path={state.model?.craftercms.path}
>
Expand All @@ -62,6 +62,6 @@ export default function DynamicRoute(props) {
{...props}
contentTypeMap={contentTypeMap}
/>
</Guest>
</ExperienceBuilder>
}
}
6 changes: 3 additions & 3 deletions sources/app/src/containers/Channel/Channel.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ import VideoCategories from '../../components/VideoCategories/VideoCategories.js
import NotFound from '../Errors/404';
import { parseDescriptor } from '@craftercms/content';
import { isAuthoring } from '../../components/utils';
import { Guest } from '@craftercms/experience-builder/react';
import { ExperienceBuilder } from '@craftercms/experience-builder/react';

class Channel extends Component {
constructor(props) {
Expand Down Expand Up @@ -141,7 +141,7 @@ class Channel extends Component {
];

return (
<Guest
<ExperienceBuilder
isAuthoring={isAuthoring()}
path={this.descriptorUrl}
>
Expand All @@ -155,7 +155,7 @@ class Channel extends Component {
categories={categories}
>
</VideoCategories>
</Guest>
</ExperienceBuilder>
);
}

Expand Down
6 changes: 3 additions & 3 deletions sources/app/src/containers/List/List.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import React, { Component } from 'react';
import { connect } from 'react-redux';
import { Guest } from '@craftercms/experience-builder/react';
import { ExperienceBuilder } from '@craftercms/experience-builder/react';

import { setVideoDocked } from '../../actions/videoPlayerActions';
import VideoCategories from '../../components/VideoCategories/VideoCategories.js';
Expand Down Expand Up @@ -84,14 +84,14 @@ class Channel extends Component {

render() {
return (
<Guest
<ExperienceBuilder
isAuthoring={isAuthoring()}
path="/site/website/index.xml"
>
{this.state && this.state.categories &&
<VideoCategories categories={this.state.categories} />
}
</Guest>
</ExperienceBuilder>
);
}
}
Expand Down
6 changes: 3 additions & 3 deletions sources/app/src/containers/Video/Video.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import { setHeaderGhost } from '../../actions/headerActions';
import { pageScrollTop } from '../../utils';
import { parseDescriptor } from '@craftercms/content';
import { isAuthoring } from '../../components/utils';
import { Guest } from '@craftercms/experience-builder/react';
import { ExperienceBuilder } from '@craftercms/experience-builder/react';

class Video extends Component {
state = {
Expand Down Expand Up @@ -337,7 +337,7 @@ class Video extends Component {
{this.state.notFound && <NotFound />}

{this.state.videoModel &&
<Guest
<ExperienceBuilder
isAuthoring={isAuthoring()}
path={this.state.videoModel.craftercms.path}
>
Expand Down Expand Up @@ -366,7 +366,7 @@ class Video extends Component {

{/* <VideoSidebar/> */}
</VideoHolder>
</Guest>
</ExperienceBuilder>
}
</div>

Expand Down
Loading

0 comments on commit ac66143

Please sign in to comment.