Skip to content

Commit

Permalink
a fix for events?
Browse files Browse the repository at this point in the history
  • Loading branch information
robotastic committed Oct 3, 2024
1 parent 591e245 commit f6853d6
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 37 deletions.
2 changes: 1 addition & 1 deletion backend/db.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
var { callModel: Call } = require("./models/call");
var Call = require("./models/call");
var Event = require("./models/event");
var Podcast = require("./models/podcast");

Expand Down
22 changes: 0 additions & 22 deletions frontend/src/Call/CallPlayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -217,35 +217,13 @@ function CallPlayer(props) {
<div className="mediaplayer">
<MediaPlayer call={currentCall} playSilence={silenceCount} onEnded={callEnded} onPlayPause={handlePlayPause} />
</div>

{/* <div className="button-item desktop-only"><SupportModal trigger={<Button color='grey' animated='fade' size={"small"}>
<ButtonContent visible color="red">
<Icon name='heart' /> Donate
</ButtonContent>
<ButtonContent hidden>Thank You</ButtonContent>
</Button>} /></div> */}
<div className="link-item desktop-only" >
<a href={callDownload}><Icon name="download" />Download</a>
</div>
<div className="link-item desktop-only">
<a href={callLink}><Icon name="at" />Link</a>
</div>

</div>


{/* <Menu.Item active={autoPlay} onClick={() => handleAutoPlay(autoPlay)}><Icon name="level up" /><span className="desktop-only">Autoplay</span></Menu.Item>
<MediaPlayer call={currentCall} playSilence={silenceCount} onEnded={callEnded} onPlayPause={handlePlayPause} />
<Menu.Menu position="right" className="desktop-only">
<Menu.Item><SupportModal trigger={<Button color='grey' animated='fade'>
<ButtonContent visible color="red">
<Icon name='heart' /> Donate
</ButtonContent>
<ButtonContent hidden>Thank You</ButtonContent>
</Button>} /></Menu.Item>
<Menu.Item><a href={callDownload}><Icon name="download" />Download</a></Menu.Item>
<Menu.Item><a href={callLink}><Icon name="at" />Link</a></Menu.Item>
</Menu.Menu> */}
</Menu>

</div>
Expand Down
32 changes: 18 additions & 14 deletions frontend/src/Event/EventPlayer.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,10 @@ function EventPlayer(props) {
}
}, [selectCallId, eventData])


let autoplayClassName = "button-item";
if (autoPlay) {
autoplayClassName += " active";
}
return (
<div ref={positionRef}>
<Container className="main" >
Expand All @@ -114,19 +117,20 @@ function EventPlayer(props) {
</Rail>
</Container>

<Menu fixed="bottom" compact inverted >
<Menu.Item active={autoPlay} onClick={() => handleAutoPlay(autoPlay)}><Icon name="level up" /><span className="desktop-only">Autoplay</span></Menu.Item>
<MediaPlayer call={currentCall} onEnded={callEnded} onPlayPause={handlePlayPause} />
<Menu.Menu position="right" className="desktop-only">
<Menu.Item><SupportModal trigger={<Button color='grey' animated='fade'>
<ButtonContent visible color="red">
<Icon name='heart' /> Donate
</ButtonContent>
<ButtonContent hidden>Thank You</ButtonContent>
</Button>} /></Menu.Item>
<Menu.Item><a href={callDownload}><Icon name="download" />Download</a></Menu.Item>
<Menu.Item><a href={callLink}><Icon name="at" />Link</a></Menu.Item>
</Menu.Menu>

<Menu fixed="bottom" inverted vertical fluid>
<div className="item-container">
<div className={autoplayClassName} onClick={() => handleAutoPlay(autoPlay)}><Icon name="level up" /><span className="desktop-only">Autoplay</span></div>
<div className="mediaplayer">
<MediaPlayer call={currentCall} onEnded={callEnded} onPlayPause={handlePlayPause} />
</div>
<div className="link-item desktop-only" >
<a href={callDownload}><Icon name="download" />Download</a>
</div>
<div className="link-item desktop-only">
<a href={callLink}><Icon name="at" />Link</a>
</div>
</div>
</Menu>

</div>
Expand Down

0 comments on commit f6853d6

Please sign in to comment.