Skip to content

Commit

Permalink
Merge branch 'FreeTubeApp:development' into development
Browse files Browse the repository at this point in the history
This is an automated nightly publish.
  • Loading branch information
MarmadileManteater committed Aug 17, 2022
2 parents 51a19d4 + 08431a2 commit be23fe0
Show file tree
Hide file tree
Showing 6 changed files with 38 additions and 9 deletions.
6 changes: 4 additions & 2 deletions src/renderer/components/ft-video-player/ft-video-player.js
Original file line number Diff line number Diff line change
Expand Up @@ -1807,8 +1807,10 @@ export default Vue.extend({
case 77:
// M Key
// Toggle Mute
event.preventDefault()
this.toggleMute()
if (!event.metaKey) {
event.preventDefault()
this.toggleMute()
}
break
case 67:
// C Key
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,8 @@ export default Vue.extend({
if (this.hideCommentLikes) {
comment.likes = null
}
comment.text = autolinker.link(comment.text.replace(/(<(?!br>)([^>]+)>)/ig, ''))
// strip html tags but keep <br>, <b>, </b> <s>, </s>, <i>, </i>
comment.text = autolinker.link(comment.text.replace(/(<(?!br|\/?(?:b|s|i)>)([^>]+)>)/ig, ''))
if (comment.customEmojis.length > 0) {
comment.customEmojis.forEach(emoji => {
comment.text = comment.text.replace(emoji.text, `<img width="14" height="14" class="commentCustomEmoji" alt="${emoji.text.substring(2, emoji.text.length - 1)}" src="${emoji.emojiThumbnails[0].url}">`)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,26 @@
color: var(--tertiary-text-color);
}

.playlistProgressBar {
margin-left: 10px;
/* > In order to let ::-webkit-progress-value take effect, appearance needs to be set to none on the <progress> element. */
/* https://developer.mozilla.org/en-US/docs/Web/CSS/::-webkit-progress-value */
appearance: none;
}

.playlistProgressBar::-webkit-progress-value {
/* Color for filled part */
/* https://developer.mozilla.org/en-US/docs/Web/CSS/::-webkit-progress-value */
/* background-color is required to be declared here to prevent color being green */
background-color: var(--accent-color);
}

.playlistProgressBar::-webkit-progress-bar {
/* Color for unfilled part */
/* https://developer.mozilla.org/en-US/docs/Web/CSS/::-webkit-progress-bar */
background-color: var(--secondary-text-color);
}

.playlistIcon {
font-size: 20px;
padding: 10px;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,12 @@
class="playlistIndex"
>
- {{ currentVideoIndex }} / {{ playlistVideoCount }}
<progress
v-if="!shuffleEnabled && !reversePlaylist"
class="playlistProgressBar"
:value="currentVideoIndex"
:max="playlistVideoCount"
/>
</span>
<p>
<font-awesome-icon
Expand Down
5 changes: 2 additions & 3 deletions src/renderer/views/Channel/Channel.js
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,6 @@ export default Vue.extend({
this.channelDescription = autolinker.link(response.description)
this.relatedChannels = response.relatedChannels.map((channel) => {
channel.authorThumbnails[channel.authorThumbnails.length - 1].url = channel.authorThumbnails[channel.authorThumbnails.length - 1].url.replace('https://yt3.ggpht.com', `${this.currentInvidiousInstance}/ggpht/`)
// Mapping authorId to channelId
channel.channelId = channel.authorId
return channel
})
Expand Down Expand Up @@ -614,7 +613,7 @@ export default Vue.extend({
message: this.$t('Channel.Channel has been removed from your subscriptions')
})

if (this.activeProfile === MAIN_PROFILE_ID) {
if (this.activeProfile._id === MAIN_PROFILE_ID) {
// Check if a subscription exists in a different profile.
// Remove from there as well.
let duplicateSubscriptions = 0
Expand Down Expand Up @@ -659,7 +658,7 @@ export default Vue.extend({
message: this.$t('Channel.Added channel to your subscriptions')
})

if (this.activeProfile !== MAIN_PROFILE_ID) {
if (this.activeProfile._id !== MAIN_PROFILE_ID) {
const index = primaryProfile.subscriptions.findIndex((channel) => {
return channel.id === this.id
})
Expand Down
7 changes: 4 additions & 3 deletions src/renderer/views/Playlist/Playlist.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,18 @@
.playlistInfo {
background-color: var(--card-bg-color);
box-sizing: border-box;
height: calc(100vh - 96px);
height: calc(100vh - 132px);
margin-right: 1em;
overflow-y: auto;
padding: 10px;
position: sticky;
top: 78px;
top: 96px;
width: 30%;
}

.playlistItems {
display: grid;
display: flex;
flex-direction: column;
grid-gap: 10px;
margin: 0;
padding: 10px;
Expand Down

0 comments on commit be23fe0

Please sign in to comment.