diff options
| author | Eric <ericmabr@gmail.com> | 2023-08-13 16:08:28 -0400 |
|---|---|---|
| committer | Eric <ericmabr@gmail.com> | 2023-08-13 16:08:28 -0400 |
| commit | 0020ec69b847c8607affb57babddfddc812dc9b6 (patch) | |
| tree | e24255039015745d2073806bee97ce449ddb5260 /src/mobile | |
| parent | 7b2553514bb000eb7f618eb0f0d653baee78742c (diff) | |
| parent | 3b45f1d30a947dc1702ec347b83e98374c5b603c (diff) | |
Merge branch 'master' into UI_Update_Eric_Ma
Diffstat (limited to 'src/mobile')
| -rw-r--r-- | src/mobile/AudioUpload.tsx | 10 | ||||
| -rw-r--r-- | src/mobile/ImageUpload.tsx | 2 | ||||
| -rw-r--r-- | src/mobile/MobileInterface.tsx | 22 | ||||
| -rw-r--r-- | src/mobile/MobileMain.tsx | 2 |
4 files changed, 18 insertions, 18 deletions
diff --git a/src/mobile/AudioUpload.tsx b/src/mobile/AudioUpload.tsx index c3423e2a5..7a1dde9fb 100644 --- a/src/mobile/AudioUpload.tsx +++ b/src/mobile/AudioUpload.tsx @@ -25,8 +25,8 @@ export class AudioUpload extends React.Component { title: 'mobile audio', _width: 300, _height: 300, - _layoutFitContentsToBox: true, - boxShadow: '0 0', + _layout_fitContentsToBox: true, + layout_boxShadow: '0 0', }), Doc ) @@ -54,7 +54,7 @@ export class AudioUpload extends React.Component { Doc ) as Doc, ], - { title: 'mobile audio', _width: 300, _height: 300, _layoutFitContentsToBox: true, boxShadow: '0 0' } + { title: 'mobile audio', _width: 300, _height: 300, _layout_fitContentsToBox: true, layout_boxShadow: '0 0' } ), Doc ) @@ -110,8 +110,8 @@ export class AudioUpload extends React.Component { pinToPres={emptyFunction} rootSelected={returnTrue} removeDocument={undefined} - docFilters={returnEmptyFilter} - docRangeFilters={returnEmptyFilter} + childFilters={returnEmptyFilter} + childFiltersByRanges={returnEmptyFilter} searchFilterDocs={returnEmptyDoclist} ScreenToLocalTransform={Transform.Identity} PanelWidth={() => 600} diff --git a/src/mobile/ImageUpload.tsx b/src/mobile/ImageUpload.tsx index f910d765e..da38fcaee 100644 --- a/src/mobile/ImageUpload.tsx +++ b/src/mobile/ImageUpload.tsx @@ -42,7 +42,7 @@ export class Uploader extends React.Component<ImageUploadProps> { this.process = "Uploading Files"; for (let index = 0; index < files.length; ++index) { const file = files[index]; - const res = await Networking.UploadFilesToServer(file); + const res = await Networking.UploadFilesToServer({file}); this.setOpacity(3, "1"); // Slab 3 // For each item that the user has selected res.map(async ({ result }) => { diff --git a/src/mobile/MobileInterface.tsx b/src/mobile/MobileInterface.tsx index a543c2f70..584a7b432 100644 --- a/src/mobile/MobileInterface.tsx +++ b/src/mobile/MobileInterface.tsx @@ -260,7 +260,7 @@ export class MobileInterface extends React.Component { @action componentDidMount = () => { // if the home menu is in list view -> adjust the menu toggle appropriately - this._menuListView = this._homeDoc._viewType === 'stacking' ? true : false; + this._menuListView = this._homeDoc._type_collection === 'stacking' ? true : false; Doc.ActiveTool = InkTool.None; // ink should intially be set to none Doc.UserDoc().activeMobile = this._homeDoc; // active mobile set to home AudioBox.Enabled = true; @@ -402,8 +402,8 @@ export class MobileInterface extends React.Component { docViewPath={returnEmptyDoclist} whenChildContentsActiveChanged={emptyFunction} bringToFront={emptyFunction} - docFilters={returnEmptyFilter} - docRangeFilters={returnEmptyFilter} + childFilters={returnEmptyFilter} + childFiltersByRanges={returnEmptyFilter} searchFilterDocs={returnEmptyDoclist} /> </div> @@ -614,7 +614,7 @@ export class MobileInterface extends React.Component { // The static ink menu that appears at the top @computed get inkMenu() { - return this._activeDoc._viewType !== CollectionViewType.Docking || !this._ink ? null : <div className="colorSelector">{/* <CollectionFreeFormViewChrome /> */}</div>; + return this._activeDoc._type_collection !== CollectionViewType.Docking || !this._ink ? null : <div className="colorSelector">{/* <CollectionFreeFormViewChrome /> */}</div>; } // DocButton that uses UndoManager and handles the opacity change if CanUndo is true @@ -657,7 +657,7 @@ export class MobileInterface extends React.Component { // DocButton for switching into ink mode @computed get drawInk() { - return !this.mainContainer || this._activeDoc._viewType !== CollectionViewType.Docking ? null : ( + return !this.mainContainer || this._activeDoc._type_collection !== CollectionViewType.Docking ? null : ( <div className="docButton" id="inkButton" title={Doc.isDocPinned(this._activeDoc) ? 'Pen on' : 'Pen off'} onClick={this.onSwitchInking}> <FontAwesomeIcon className="documentdecorations-icon" size="sm" icon="pen-nib" /> </div> @@ -666,7 +666,7 @@ export class MobileInterface extends React.Component { // DocButton: Button that appears on the bottom of the screen to initiate image upload @computed get uploadImageButton() { - if (this._activeDoc.type === DocumentType.COL && this._activeDoc !== this._homeDoc && this._activeDoc._viewType !== CollectionViewType.Docking && this._activeDoc.title !== 'WORKSPACES') { + if (this._activeDoc.type === DocumentType.COL && this._activeDoc !== this._homeDoc && this._activeDoc._type_collection !== CollectionViewType.Docking && this._activeDoc.title !== 'WORKSPACES') { return ( <div className="docButton" id="imageButton" title={Doc.isDocPinned(this._activeDoc) ? 'Pen on' : 'Pen off'} onClick={this.toggleUpload}> <FontAwesomeIcon className="documentdecorations-icon" size="sm" icon="upload" /> @@ -722,9 +722,9 @@ export class MobileInterface extends React.Component { // Logic for switching the menu into the icons @action changeToIconView = () => { - if ((this._homeDoc._viewType = 'stacking')) { + if ((this._homeDoc._type_collection = 'stacking')) { this._menuListView = false; - this._homeDoc._viewType = 'masonry'; + this._homeDoc._type_collection = 'masonry'; this._homeDoc.columnWidth = 300; this._homeDoc._columnWidth = 300; const menuButtons = DocListCast(this._homeDoc.data); @@ -742,8 +742,8 @@ export class MobileInterface extends React.Component { // Logic for switching the menu into the stacking view @action changeToListView = () => { - if ((this._homeDoc._viewType = 'masonry')) { - this._homeDoc._viewType = 'stacking'; + if ((this._homeDoc._type_collection = 'masonry')) { + this._homeDoc._type_collection = 'stacking'; this._menuListView = true; const menuButtons = DocListCast(this._homeDoc.data); menuButtons.map(doc => { @@ -800,7 +800,7 @@ export class MobileInterface extends React.Component { // Radial menu can only be used if it is a colleciton and it is not a homeDoc // (and cannot be used on Dashboard to avoid pin to presentation opening on right) @computed get displayRadialMenu() { - return this._activeDoc.type === 'collection' && this._activeDoc !== this._homeDoc && this._activeDoc._viewType !== CollectionViewType.Docking ? <RadialMenu /> : null; + return this._activeDoc.type === 'collection' && this._activeDoc !== this._homeDoc && this._activeDoc._type_collection !== CollectionViewType.Docking ? <RadialMenu /> : null; } onDragOver = (e: React.DragEvent) => { diff --git a/src/mobile/MobileMain.tsx b/src/mobile/MobileMain.tsx index 6cbf86f77..dc3a73def 100644 --- a/src/mobile/MobileMain.tsx +++ b/src/mobile/MobileMain.tsx @@ -12,7 +12,7 @@ AssignAllExtensions(); const info = await CurrentUserUtils.loadCurrentUser(); DocServer.init(window.location.protocol, window.location.hostname, 4321, info.email + ' (mobile)'); await Docs.Prototypes.initialize(); - await CurrentUserUtils.loadUserDocument(info.id); + await CurrentUserUtils.loadUserDocument(info); document.getElementById('root')!.addEventListener( 'wheel', event => { |
