@penwin/discord-components-core 4.3.8 → 4.3.9-dev-32918495512.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +826 -826
- package/LICENSE.md +20 -0
- package/README.md +673 -673
- package/custom-elements.json +1803 -1708
- package/dist/bundle/index.mjs +1976 -1976
- package/dist/bundle/index.mjs.map +1 -1
- package/dist/bundle/styles/base.css +1 -2
- package/dist/components/_private/BaseDiscordSelectMenuOption.js +72 -72
- package/dist/components/_private/DiscordMediaAttachmentStyles.js +114 -114
- package/dist/components/_private/DiscordPlaybackControlStyles.js +153 -153
- package/dist/components/_private/DiscordVolumeControlStyles.js +158 -158
- package/dist/components/_private/DiscordWhiteSpace.js +4 -4
- package/dist/components/discord-action-row/DiscordActionRow.js +6 -6
- package/dist/components/discord-attachments/DiscordAttachments.js +18 -18
- package/dist/components/discord-audio-attachment/DiscordAudioAttachment.js +202 -202
- package/dist/components/discord-author-info/DiscordAuthorInfo.d.ts.map +1 -1
- package/dist/components/discord-author-info/DiscordAuthorInfo.js +156 -156
- package/dist/components/discord-author-info/DiscordAuthorInfo.js.map +1 -1
- package/dist/components/discord-bold/DiscordBold.js +4 -4
- package/dist/components/discord-button/DiscordButton.d.ts.map +1 -1
- package/dist/components/discord-button/DiscordButton.js +131 -128
- package/dist/components/discord-button/DiscordButton.js.map +1 -1
- package/dist/components/discord-channel-select-menu-option/DiscordChannelSelectMenuOption.js +131 -131
- package/dist/components/discord-code/DiscordCode.js +64 -64
- package/dist/components/discord-code-block/DiscordCodeBlock.js +2 -2
- package/dist/components/discord-command/DiscordCommand.js +109 -109
- package/dist/components/discord-components-column/DiscordComponentsColumn.js +18 -18
- package/dist/components/discord-container/DiscordContainer.js +47 -47
- package/dist/components/discord-custom-emoji/DiscordCustomEmoji.js +36 -36
- package/dist/components/discord-embed/DiscordEmbed.d.ts.map +1 -1
- package/dist/components/discord-embed/DiscordEmbed.js +285 -285
- package/dist/components/discord-embed/DiscordEmbed.js.map +1 -1
- package/dist/components/discord-embed-description/DiscordEmbedDescription.js +25 -25
- package/dist/components/discord-embed-field/DiscordEmbedField.js +40 -40
- package/dist/components/discord-embed-fields/DiscordEmbedFields.js +19 -19
- package/dist/components/discord-embed-footer/DiscordEmbedFooter.js +36 -36
- package/dist/components/discord-file-attachment/DiscordFileAttachment.js +191 -191
- package/dist/components/discord-forwarded-message/DiscordForwardedMessage.js +126 -126
- package/dist/components/discord-header/DiscordHeader.js +27 -27
- package/dist/components/discord-image-attachment/DiscordImageAttachment.js +38 -38
- package/dist/components/discord-input-text/DiscordInputText.js +284 -284
- package/dist/components/discord-invite/DiscordInvite.js +225 -225
- package/dist/components/discord-italic/DiscordItalic.js +4 -4
- package/dist/components/discord-link/DiscordLink.js +19 -19
- package/dist/components/discord-list-item/DiscordListItem.d.ts.map +1 -1
- package/dist/components/discord-list-item/DiscordListItem.js +8 -5
- package/dist/components/discord-list-item/DiscordListItem.js.map +1 -1
- package/dist/components/discord-media-fullscreen-previewer/DiscordMediaFullscreenPreviewer.js +463 -463
- package/dist/components/discord-media-gallery/DiscordMediaGallery.js +219 -219
- package/dist/components/discord-media-gallery-item/DiscordMediaGalleryItem.d.ts.map +1 -1
- package/dist/components/discord-media-gallery-item/DiscordMediaGalleryItem.js +102 -99
- package/dist/components/discord-media-gallery-item/DiscordMediaGalleryItem.js.map +1 -1
- package/dist/components/discord-media-spoileable-cover/DiscordMediaSpoileableCover.js +65 -65
- package/dist/components/discord-mention/DiscordMention.js +66 -66
- package/dist/components/discord-message/DiscordMessage.d.ts.map +1 -1
- package/dist/components/discord-message/DiscordMessage.js +338 -335
- package/dist/components/discord-message/DiscordMessage.js.map +1 -1
- package/dist/components/discord-messages/DiscordMessages.js +77 -77
- package/dist/components/discord-modal/DiscordModal.js +465 -465
- package/dist/components/discord-ordered-list/DiscordOrderedList.d.ts.map +1 -1
- package/dist/components/discord-ordered-list/DiscordOrderedList.js +20 -14
- package/dist/components/discord-ordered-list/DiscordOrderedList.js.map +1 -1
- package/dist/components/discord-poll/DiscordPoll.js +157 -157
- package/dist/components/discord-poll-answer/DiscordPollAnswer.js +227 -227
- package/dist/components/discord-pre/DiscordPre.js +18 -18
- package/dist/components/discord-quote/DiscordQuote.js +31 -31
- package/dist/components/discord-reaction/DiscordReaction.js +73 -73
- package/dist/components/discord-reactions/DiscordReactions.js +9 -9
- package/dist/components/discord-reply/DiscordReply.d.ts.map +1 -1
- package/dist/components/discord-reply/DiscordReply.js +246 -246
- package/dist/components/discord-reply/DiscordReply.js.map +1 -1
- package/dist/components/discord-role-select-menu-option/DiscordRoleSelectMenuOption.js +75 -75
- package/dist/components/discord-section/DiscordSection.js +6 -6
- package/dist/components/discord-section-components/DiscordSectionComponents.js +14 -14
- package/dist/components/discord-select-menu-portal/DiscordSelectMenuPortal.js +30 -30
- package/dist/components/discord-separator/DiscordSeparator.js +9 -9
- package/dist/components/discord-spoiler/DiscordSpoiler.js +31 -31
- package/dist/components/discord-string-select-menu/DiscordStringSelectMenu.js +192 -192
- package/dist/components/discord-string-select-menu-option/DiscordStringSelectMenuOption.js +45 -45
- package/dist/components/discord-subscript/DiscordSubscript.js +15 -15
- package/dist/components/discord-system-message/DiscordSystemMessage.d.ts.map +1 -1
- package/dist/components/discord-system-message/DiscordSystemMessage.js +134 -131
- package/dist/components/discord-system-message/DiscordSystemMessage.js.map +1 -1
- package/dist/components/discord-tenor-video/DiscordTenorVideo.js +76 -76
- package/dist/components/discord-text-display/DiscordTextDisplay.js +10 -10
- package/dist/components/discord-text-file-attachment-previewer/DiscordTextFileAttachmentPreviewer.js +55 -55
- package/dist/components/discord-thread/DiscordThread.js +81 -81
- package/dist/components/discord-thread-message/DiscordThreadMessage.js +90 -90
- package/dist/components/discord-thumbnail/DiscordThumbnail.js +20 -20
- package/dist/components/discord-time/DiscordTime.js +7 -7
- package/dist/components/discord-transcript-header/DiscordTranscriptHeader.js +51 -51
- package/dist/components/discord-unordered-list/DiscordUnorderedList.d.ts.map +1 -1
- package/dist/components/discord-unordered-list/DiscordUnorderedList.js +18 -15
- package/dist/components/discord-unordered-list/DiscordUnorderedList.js.map +1 -1
- package/dist/components/discord-user-select-menu-option/DiscordUserSelectMenuOption.js +58 -58
- package/dist/components/discord-verified-author-tag/DiscordVerifiedAuthorTag.js +36 -36
- package/dist/components/discord-video-attachment/DiscordVideoAttachment.js +494 -494
- package/dist/components/discord-voice-message/DiscordVoiceMessage.js +255 -255
- package/dist/components/svgs/AttachmentDownloadButton.js +67 -67
- package/dist/components/svgs/AttachmentReply.js +5 -5
- package/dist/components/svgs/Boost.js +3 -3
- package/dist/components/svgs/ChannelForum.js +19 -19
- package/dist/components/svgs/ChannelIcon.js +17 -17
- package/dist/components/svgs/ChannelThread.js +15 -15
- package/dist/components/svgs/ChannelsAndRoles.js +23 -23
- package/dist/components/svgs/CommandIcon.js +4 -4
- package/dist/components/svgs/CommandIconName.js +5 -5
- package/dist/components/svgs/CommandReply.js +9 -9
- package/dist/components/svgs/CustomizeCommunity.js +17 -17
- package/dist/components/svgs/DMCall.js +6 -6
- package/dist/components/svgs/DMEdit.js +8 -8
- package/dist/components/svgs/DMMissedCall.js +8 -8
- package/dist/components/svgs/Ephemeral.js +21 -21
- package/dist/components/svgs/ExpandMore.js +4 -4
- package/dist/components/svgs/FileAttachment.js +10 -10
- package/dist/components/svgs/GuildBadge.js +8 -8
- package/dist/components/svgs/LaunchIcon.js +9 -9
- package/dist/components/svgs/LockedVoiceChannel.js +17 -17
- package/dist/components/svgs/MediaPauseIcon.js +2 -2
- package/dist/components/svgs/MediaPlayIcon.js +2 -2
- package/dist/components/svgs/MediaRestartIcon.js +2 -2
- package/dist/components/svgs/MediaVolumeAbove50PercentIcon.js +3 -3
- package/dist/components/svgs/MediaVolumeBelow50PercentIcon.js +2 -2
- package/dist/components/svgs/MediaVolumeMutedIcon.js +2 -2
- package/dist/components/svgs/MessageIcon.js +3 -3
- package/dist/components/svgs/ModalClose.js +4 -4
- package/dist/components/svgs/ModalWarning.js +5 -5
- package/dist/components/svgs/PartnerBadgeOverlay.js +11 -11
- package/dist/components/svgs/Pin.js +5 -5
- package/dist/components/svgs/PremiumIcon.js +6 -6
- package/dist/components/svgs/ReplyIcon.js +5 -5
- package/dist/components/svgs/ServerGuide.js +17 -17
- package/dist/components/svgs/ServerUpgrade.js +7 -7
- package/dist/components/svgs/SystemAlert.js +7 -7
- package/dist/components/svgs/SystemError.js +6 -6
- package/dist/components/svgs/Thread.js +9 -9
- package/dist/components/svgs/UserJoin.js +5 -5
- package/dist/components/svgs/UserLeave.js +5 -5
- package/dist/components/svgs/VerifiedBadgeOverlay.js +4 -4
- package/dist/components/svgs/VerifiedTick.js +13 -13
- package/dist/components/svgs/VideoFullScreenIcon.js +8 -8
- package/dist/components/svgs/VideoPausePopIcon.js +2 -2
- package/dist/components/svgs/VideoPlayPopIcon.js +2 -2
- package/dist/components/svgs/VoiceChannel.js +19 -19
- package/dist/components/svgs/clan-icons/Crystal.js +27 -27
- package/dist/components/svgs/clan-icons/Diamond.js +35 -35
- package/dist/components/svgs/clan-icons/Explosion.js +30 -30
- package/dist/components/svgs/clan-icons/Flame.js +23 -23
- package/dist/components/svgs/clan-icons/Flower.js +18 -18
- package/dist/components/svgs/clan-icons/Heart.js +19 -19
- package/dist/components/svgs/clan-icons/Key.js +32 -32
- package/dist/components/svgs/clan-icons/Leaf.js +23 -23
- package/dist/components/svgs/clan-icons/Lightning.js +25 -25
- package/dist/components/svgs/clan-icons/Magic.js +34 -34
- package/dist/components/svgs/clan-icons/Moon.js +21 -21
- package/dist/components/svgs/clan-icons/Mushroom.js +33 -33
- package/dist/components/svgs/clan-icons/Mythical.js +32 -32
- package/dist/components/svgs/clan-icons/Ornament.js +48 -48
- package/dist/components/svgs/clan-icons/Plasma.js +23 -23
- package/dist/components/svgs/clan-icons/Rock.js +20 -20
- package/dist/components/svgs/clan-icons/Shell.js +29 -29
- package/dist/components/svgs/clan-icons/Skull.js +28 -28
- package/dist/components/svgs/clan-icons/Sun.js +36 -36
- package/dist/components/svgs/clan-icons/Sword.js +27 -27
- package/dist/components/svgs/clan-icons/Water.js +20 -20
- package/dist/config.d.ts +1 -1
- package/dist/config.d.ts.map +1 -1
- package/dist/config.js +9 -3
- package/dist/config.js.map +1 -1
- package/dist/hydrate/index.d.ts +40 -0
- package/dist/hydrate/index.d.ts.map +1 -0
- package/dist/hydrate/index.js +48 -0
- package/dist/hydrate/index.js.map +1 -0
- package/package.json +222 -219
- package/dist/bundle/styles/base.css.map +0 -1
- package/dist/components/discord-container copy/DiscordContainer.d.ts +0 -22
- package/dist/components/discord-container copy/DiscordContainer.d.ts.map +0 -1
- package/dist/components/discord-container copy/DiscordContainer.js +0 -159
- package/dist/components/discord-container copy/DiscordContainer.js.map +0 -1
- package/dist/components/discord-media-fullscreen-previewer/context.d.ts +0 -10
- package/dist/components/discord-media-fullscreen-previewer/context.d.ts.map +0 -1
- package/dist/components/discord-media-fullscreen-previewer/context.js +0 -3
- package/dist/components/discord-media-fullscreen-previewer/context.js.map +0 -1
- package/dist/components/discord-media-gallery-tem/DiscordMediaGalleryItem.d.ts +0 -26
- package/dist/components/discord-media-gallery-tem/DiscordMediaGalleryItem.d.ts.map +0 -1
- package/dist/components/discord-media-gallery-tem/DiscordMediaGalleryItem.js +0 -183
- package/dist/components/discord-media-gallery-tem/DiscordMediaGalleryItem.js.map +0 -1
- package/dist/components/discord-section/DiscordContainer.d.ts +0 -22
- package/dist/components/discord-section/DiscordContainer.d.ts.map +0 -1
- package/dist/components/discord-section/DiscordContainer.js +0 -159
- package/dist/components/discord-section/DiscordContainer.js.map +0 -1
- package/dist/components/discord-section copy/DiscordSection.d.ts +0 -15
- package/dist/components/discord-section copy/DiscordSection.d.ts.map +0 -1
- package/dist/components/discord-section copy/DiscordSection.js +0 -77
- package/dist/components/discord-section copy/DiscordSection.js.map +0 -1
- package/dist/components/discord-section-components/DiscordSection.d.ts +0 -15
- package/dist/components/discord-section-components/DiscordSection.d.ts.map +0 -1
- package/dist/components/discord-section-components/DiscordSection.js +0 -77
- package/dist/components/discord-section-components/DiscordSection.js.map +0 -1
- package/dist/components/discord-text-display/DiscordSection.d.ts +0 -15
- package/dist/components/discord-text-display/DiscordSection.d.ts.map +0 -1
- package/dist/components/discord-text-display/DiscordSection.js +0 -79
- package/dist/components/discord-text-display/DiscordSection.js.map +0 -1
- package/dist/components/discord-text-file-attachment-preview/DiscordTextFileAttachmentPreviewer.d.ts +0 -71
- package/dist/components/discord-text-file-attachment-preview/DiscordTextFileAttachmentPreviewer.d.ts.map +0 -1
- package/dist/components/discord-text-file-attachment-preview/DiscordTextFileAttachmentPreviewer.js +0 -238
- package/dist/components/discord-text-file-attachment-preview/DiscordTextFileAttachmentPreviewer.js.map +0 -1
|
@@ -80,77 +80,77 @@ let DiscordCommand = class DiscordCommand extends LitElement {
|
|
|
80
80
|
*/
|
|
81
81
|
static { this.styles = [
|
|
82
82
|
DiscordReply.styles,
|
|
83
|
-
css `
|
|
84
|
-
:host .discord-slash-command-name {
|
|
85
|
-
color: color-mix(in oklab, hsl(200 calc(1 * 100%) 49.4% / 1) 100%, black 0%) !important;
|
|
86
|
-
font-weight: 500;
|
|
87
|
-
background-color: #3c4270;
|
|
88
|
-
border-radius: 3px;
|
|
89
|
-
display: flex;
|
|
90
|
-
padding: 0 5px;
|
|
91
|
-
align-items: center;
|
|
92
|
-
gap: 2px;
|
|
93
|
-
cursor: default;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
:host([light-theme]) .discord-slash-command-name {
|
|
97
|
-
background-color: hsl(235deg 85.6% 64.7% / 15%);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
:host .discord-slash-command-name:hover {
|
|
101
|
-
color: #fffffd !important;
|
|
102
|
-
background-color: #5865f2;
|
|
103
|
-
}
|
|
104
|
-
|
|
105
|
-
.discord-context-command-name {
|
|
106
|
-
color: color-mix(in oklab, hsl(200 calc(1 * 100%) 49.4% / 1) 100%, black 0%) !important;
|
|
107
|
-
opacity: 0.64;
|
|
108
|
-
cursor: default;
|
|
109
|
-
font-weight: 500;
|
|
110
|
-
}
|
|
111
|
-
|
|
112
|
-
.discord-arrow-right-icon {
|
|
113
|
-
transform: rotate(267deg);
|
|
114
|
-
width: 12px;
|
|
115
|
-
height: 12px;
|
|
116
|
-
fill: none;
|
|
117
|
-
margin-right: 2px;
|
|
118
|
-
margin-left: 2px;
|
|
119
|
-
margin-top: 3px;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
.discord-context-user {
|
|
123
|
-
display: flex;
|
|
124
|
-
align-items: center;
|
|
125
|
-
margin-top: 3px;
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
.discord-message-margintop {
|
|
129
|
-
margin-top: 3px;
|
|
130
|
-
}
|
|
131
|
-
|
|
132
|
-
:host .discord-message-deleted {
|
|
133
|
-
color: rgb(185, 187, 190) !important;
|
|
134
|
-
cursor: default;
|
|
135
|
-
}
|
|
136
|
-
|
|
137
|
-
:host .discord-replied-message-username {
|
|
138
|
-
margin-right: 0;
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
:host([light-theme]) .discord-replied-message-username {
|
|
142
|
-
color: rgb(46, 51, 56);
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
:host([compact-mode]) .discord-context-user {
|
|
146
|
-
display: flex;
|
|
147
|
-
align-items: center;
|
|
148
|
-
margin: 0 !important;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
:host([compact-mode]) .discord-message-margintop {
|
|
152
|
-
margin-top: 0 !important;
|
|
153
|
-
}
|
|
83
|
+
css `
|
|
84
|
+
:host .discord-slash-command-name {
|
|
85
|
+
color: color-mix(in oklab, hsl(200 calc(1 * 100%) 49.4% / 1) 100%, black 0%) !important;
|
|
86
|
+
font-weight: 500;
|
|
87
|
+
background-color: #3c4270;
|
|
88
|
+
border-radius: 3px;
|
|
89
|
+
display: flex;
|
|
90
|
+
padding: 0 5px;
|
|
91
|
+
align-items: center;
|
|
92
|
+
gap: 2px;
|
|
93
|
+
cursor: default;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
:host([light-theme]) .discord-slash-command-name {
|
|
97
|
+
background-color: hsl(235deg 85.6% 64.7% / 15%);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
:host .discord-slash-command-name:hover {
|
|
101
|
+
color: #fffffd !important;
|
|
102
|
+
background-color: #5865f2;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.discord-context-command-name {
|
|
106
|
+
color: color-mix(in oklab, hsl(200 calc(1 * 100%) 49.4% / 1) 100%, black 0%) !important;
|
|
107
|
+
opacity: 0.64;
|
|
108
|
+
cursor: default;
|
|
109
|
+
font-weight: 500;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.discord-arrow-right-icon {
|
|
113
|
+
transform: rotate(267deg);
|
|
114
|
+
width: 12px;
|
|
115
|
+
height: 12px;
|
|
116
|
+
fill: none;
|
|
117
|
+
margin-right: 2px;
|
|
118
|
+
margin-left: 2px;
|
|
119
|
+
margin-top: 3px;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
.discord-context-user {
|
|
123
|
+
display: flex;
|
|
124
|
+
align-items: center;
|
|
125
|
+
margin-top: 3px;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
.discord-message-margintop {
|
|
129
|
+
margin-top: 3px;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
:host .discord-message-deleted {
|
|
133
|
+
color: rgb(185, 187, 190) !important;
|
|
134
|
+
cursor: default;
|
|
135
|
+
}
|
|
136
|
+
|
|
137
|
+
:host .discord-replied-message-username {
|
|
138
|
+
margin-right: 0;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
:host([light-theme]) .discord-replied-message-username {
|
|
142
|
+
color: rgb(46, 51, 56);
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
:host([compact-mode]) .discord-context-user {
|
|
146
|
+
display: flex;
|
|
147
|
+
align-items: center;
|
|
148
|
+
margin: 0 !important;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
:host([compact-mode]) .discord-message-margintop {
|
|
152
|
+
margin-top: 0 !important;
|
|
153
|
+
}
|
|
154
154
|
`
|
|
155
155
|
]; }
|
|
156
156
|
checkType() {
|
|
@@ -187,44 +187,44 @@ let DiscordCommand = class DiscordCommand extends LitElement {
|
|
|
187
187
|
const contentContextMessage = this.contextMessageDeleted
|
|
188
188
|
? html `<em class="discord-message-deleted">Original message was deleted</em>`
|
|
189
189
|
: this.contextMessageReply;
|
|
190
|
-
return html `
|
|
191
|
-
${when(this.compactMode, () => html `<div class="discord-reply-badge">${CommandIcon()}</div>`, () => html `<img class="discord-replied-message-avatar" src="${ifDefined(profile.avatar)}" alt="${ifDefined(profile.author)}" />`)}
|
|
192
|
-
<span class="discord-replied-message-username" style=${styleMap({ color: profile.roleColor ?? '' })}>${profile.author}</span>
|
|
193
|
-
<span> used </span>
|
|
194
|
-
${when(this.type === 'slash_command', () => html `<div class="discord-replied-message-content discord-slash-command-name">
|
|
195
|
-
${CommandIconName()}<span>${this.command}</span>
|
|
196
|
-
</div>`)}
|
|
197
|
-
${when(this.type === 'user_command', () => html `<div class="discord-replied-message-content discord-context-command-name"><span>${this.command}</span></div>
|
|
198
|
-
${ExpandMore({ class: 'discord-arrow-right-icon' })}
|
|
199
|
-
<div class="discord-context-user">
|
|
200
|
-
${when(!this.compactMode, () => html `<img
|
|
201
|
-
class="discord-replied-message-avatar"
|
|
202
|
-
src="${ifDefined(profileContext.avatar)}"
|
|
203
|
-
alt="${ifDefined(profileContext.author)}"
|
|
204
|
-
/>`)}
|
|
205
|
-
<span class="discord-replied-message-username" style=${styleMap({ color: profileContext.roleColor ?? '' })}
|
|
206
|
-
>${profileContext.author}</span
|
|
207
|
-
>
|
|
208
|
-
</div>`)}
|
|
209
|
-
${when(this.type === 'message_command', () => html `<div class="discord-replied-message-content discord-context-command-name"><span>${this.command}</span></div>
|
|
210
|
-
${ExpandMore({ class: 'discord-arrow-right-icon' })}
|
|
211
|
-
${when(!this.contextMessageDeleted, () => html `<div class="discord-context-user">
|
|
212
|
-
${when(!this.compactMode, () => when(!this.contextUserOfficialApplication, () => html `<img
|
|
213
|
-
class="discord-replied-message-avatar"
|
|
214
|
-
src="${ifDefined(profileContext.avatar)}"
|
|
215
|
-
alt="${ifDefined(profileContext.author)}"
|
|
216
|
-
/>`, () => html `<img
|
|
217
|
-
class="discord-replied-message-avatar"
|
|
218
|
-
src="${ifDefined(avatars.blue)}"
|
|
219
|
-
alt="OFFICIALAPPLICATION"
|
|
220
|
-
/>`))}
|
|
221
|
-
${when(profileContext.bot, () => html `<span class="discord-application-tag">${profileContext.verified ? VerifiedTick() : ''}App</span>`, () => when(this.contextUserServer, () => html `<span class="discord-application-tag">SERVER</span>`, () => when(this.contextUserOfficialApplication, () => html `<span class="discord-application-tag">${VerifiedTick()}OFFICIAL</span>`)))}
|
|
222
|
-
<span class="discord-replied-message-username" style=${styleMap({ color: profileContext.roleColor ?? '' })}
|
|
223
|
-
>${profileContext.author}</span
|
|
224
|
-
><span></span>
|
|
225
|
-
</div>`, () => when(this.contextMessageDeleted, () => MessageIcon({ class: 'discord-message-margintop', style: 'margin-right: 3px;' })))}
|
|
226
|
-
<div class="discord-replied-message-content discord-message-margintop">${contentContextMessage}</div>
|
|
227
|
-
${when(this.contextCommandReply && !this.contextMessageDeleted, () => CommandReply({ class: 'discord-replied-message-content-icon discord-message-margintop' }), () => when(this.contextAttachmentReply, () => AttachmentReply({ class: 'discord-replied-message-content-icon discord-message-margintop' })))} `)}
|
|
190
|
+
return html `
|
|
191
|
+
${when(this.compactMode, () => html `<div class="discord-reply-badge">${CommandIcon()}</div>`, () => html `<img class="discord-replied-message-avatar" src="${ifDefined(profile.avatar)}" alt="${ifDefined(profile.author)}" />`)}
|
|
192
|
+
<span class="discord-replied-message-username" style=${styleMap({ color: profile.roleColor ?? '' })}>${profile.author}</span>
|
|
193
|
+
<span> used </span>
|
|
194
|
+
${when(this.type === 'slash_command', () => html `<div class="discord-replied-message-content discord-slash-command-name">
|
|
195
|
+
${CommandIconName()}<span>${this.command}</span>
|
|
196
|
+
</div>`)}
|
|
197
|
+
${when(this.type === 'user_command', () => html `<div class="discord-replied-message-content discord-context-command-name"><span>${this.command}</span></div>
|
|
198
|
+
${ExpandMore({ class: 'discord-arrow-right-icon' })}
|
|
199
|
+
<div class="discord-context-user">
|
|
200
|
+
${when(!this.compactMode, () => html `<img
|
|
201
|
+
class="discord-replied-message-avatar"
|
|
202
|
+
src="${ifDefined(profileContext.avatar)}"
|
|
203
|
+
alt="${ifDefined(profileContext.author)}"
|
|
204
|
+
/>`)}
|
|
205
|
+
<span class="discord-replied-message-username" style=${styleMap({ color: profileContext.roleColor ?? '' })}
|
|
206
|
+
>${profileContext.author}</span
|
|
207
|
+
>
|
|
208
|
+
</div>`)}
|
|
209
|
+
${when(this.type === 'message_command', () => html `<div class="discord-replied-message-content discord-context-command-name"><span>${this.command}</span></div>
|
|
210
|
+
${ExpandMore({ class: 'discord-arrow-right-icon' })}
|
|
211
|
+
${when(!this.contextMessageDeleted, () => html `<div class="discord-context-user">
|
|
212
|
+
${when(!this.compactMode, () => when(!this.contextUserOfficialApplication, () => html `<img
|
|
213
|
+
class="discord-replied-message-avatar"
|
|
214
|
+
src="${ifDefined(profileContext.avatar)}"
|
|
215
|
+
alt="${ifDefined(profileContext.author)}"
|
|
216
|
+
/>`, () => html `<img
|
|
217
|
+
class="discord-replied-message-avatar"
|
|
218
|
+
src="${ifDefined(avatars.blue)}"
|
|
219
|
+
alt="OFFICIALAPPLICATION"
|
|
220
|
+
/>`))}
|
|
221
|
+
${when(profileContext.bot, () => html `<span class="discord-application-tag">${profileContext.verified ? VerifiedTick() : ''}App</span>`, () => when(this.contextUserServer, () => html `<span class="discord-application-tag">SERVER</span>`, () => when(this.contextUserOfficialApplication, () => html `<span class="discord-application-tag">${VerifiedTick()}OFFICIAL</span>`)))}
|
|
222
|
+
<span class="discord-replied-message-username" style=${styleMap({ color: profileContext.roleColor ?? '' })}
|
|
223
|
+
>${profileContext.author}</span
|
|
224
|
+
><span></span>
|
|
225
|
+
</div>`, () => when(this.contextMessageDeleted, () => MessageIcon({ class: 'discord-message-margintop', style: 'margin-right: 3px;' })))}
|
|
226
|
+
<div class="discord-replied-message-content discord-message-margintop">${contentContextMessage}</div>
|
|
227
|
+
${when(this.contextCommandReply && !this.contextMessageDeleted, () => CommandReply({ class: 'discord-replied-message-content-icon discord-message-margintop' }), () => when(this.contextAttachmentReply, () => AttachmentReply({ class: 'discord-replied-message-content-icon discord-message-margintop' })))} `)}
|
|
228
228
|
`;
|
|
229
229
|
}
|
|
230
230
|
};
|
|
@@ -21,24 +21,24 @@ let DiscordComponentsColumn = class DiscordComponentsColumn extends LitElement {
|
|
|
21
21
|
/**
|
|
22
22
|
* @internal
|
|
23
23
|
*/
|
|
24
|
-
static { this.styles = css `
|
|
25
|
-
:host {
|
|
26
|
-
display: flex;
|
|
27
|
-
flex-direction: column;
|
|
28
|
-
row-gap: 8px;
|
|
29
|
-
margin-top: 8px;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
::slotted(discord-file-attachment) {
|
|
33
|
-
--media-item-container-margin-top: 0px;
|
|
34
|
-
padding-top: 0px;
|
|
35
|
-
padding-bottom: 0px;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
:host([is-in-container]),
|
|
39
|
-
:host([is-in-forwarded-message]) {
|
|
40
|
-
margin-top: 0px;
|
|
41
|
-
}
|
|
24
|
+
static { this.styles = css `
|
|
25
|
+
:host {
|
|
26
|
+
display: flex;
|
|
27
|
+
flex-direction: column;
|
|
28
|
+
row-gap: 8px;
|
|
29
|
+
margin-top: 8px;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
::slotted(discord-file-attachment) {
|
|
33
|
+
--media-item-container-margin-top: 0px;
|
|
34
|
+
padding-top: 0px;
|
|
35
|
+
padding-bottom: 0px;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
:host([is-in-container]),
|
|
39
|
+
:host([is-in-forwarded-message]) {
|
|
40
|
+
margin-top: 0px;
|
|
41
|
+
}
|
|
42
42
|
`; }
|
|
43
43
|
render() {
|
|
44
44
|
return html `<slot></slot>`;
|
|
@@ -27,57 +27,57 @@ let DiscordContainer = class DiscordContainer extends LitElement {
|
|
|
27
27
|
* @internal
|
|
28
28
|
*/
|
|
29
29
|
static { this.styles = [
|
|
30
|
-
css `
|
|
31
|
-
:host {
|
|
32
|
-
color: #dcddde;
|
|
33
|
-
display: flex;
|
|
34
|
-
font-size: 13px;
|
|
35
|
-
line-height: 150%;
|
|
36
|
-
margin-bottom: 8px;
|
|
37
|
-
margin-top: 8px;
|
|
38
|
-
width: 4px;
|
|
39
|
-
max-width: 600px;
|
|
40
|
-
overflow: hidden;
|
|
41
|
-
display: flex;
|
|
42
|
-
background-color: var(--background, #393a41);
|
|
43
|
-
border: 1px solid var(--border, #44454c);
|
|
44
|
-
border-radius: 8px;
|
|
45
|
-
width: fit-content;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
.discord-left-border {
|
|
49
|
-
width: 4px;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
:host([light-theme]) {
|
|
53
|
-
color: #2e3338;
|
|
54
|
-
--background: color-mix(in oklab, hsl(0 calc(1 * 0%) 100% /1) 100%, #000 0%);
|
|
55
|
-
--border: color-mix(in oklab, hsl(240 calc(1 * 4%) 60.784% /0.2784313725490196) 100%, hsl(0 0% 0% /0.2784313725490196) 0%);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
discord-components-column {
|
|
59
|
-
padding: 16px;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
.discord-container-custom-emoji {
|
|
63
|
-
display: inline-block;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
.discord-container-custom-emoji .discord-container-custom-emoji-image {
|
|
67
|
-
width: 18px;
|
|
68
|
-
height: 18px;
|
|
69
|
-
vertical-align: bottom;
|
|
70
|
-
}
|
|
30
|
+
css `
|
|
31
|
+
:host {
|
|
32
|
+
color: #dcddde;
|
|
33
|
+
display: flex;
|
|
34
|
+
font-size: 13px;
|
|
35
|
+
line-height: 150%;
|
|
36
|
+
margin-bottom: 8px;
|
|
37
|
+
margin-top: 8px;
|
|
38
|
+
width: 4px;
|
|
39
|
+
max-width: 600px;
|
|
40
|
+
overflow: hidden;
|
|
41
|
+
display: flex;
|
|
42
|
+
background-color: var(--background, #393a41);
|
|
43
|
+
border: 1px solid var(--border, #44454c);
|
|
44
|
+
border-radius: 8px;
|
|
45
|
+
width: fit-content;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.discord-left-border {
|
|
49
|
+
width: 4px;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
:host([light-theme]) {
|
|
53
|
+
color: #2e3338;
|
|
54
|
+
--background: color-mix(in oklab, hsl(0 calc(1 * 0%) 100% /1) 100%, #000 0%);
|
|
55
|
+
--border: color-mix(in oklab, hsl(240 calc(1 * 4%) 60.784% /0.2784313725490196) 100%, hsl(0 0% 0% /0.2784313725490196) 0%);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
discord-components-column {
|
|
59
|
+
padding: 16px;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
.discord-container-custom-emoji {
|
|
63
|
+
display: inline-block;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
.discord-container-custom-emoji .discord-container-custom-emoji-image {
|
|
67
|
+
width: 18px;
|
|
68
|
+
height: 18px;
|
|
69
|
+
vertical-align: bottom;
|
|
70
|
+
}
|
|
71
71
|
`,
|
|
72
72
|
DiscordMediaSpoileableCover.hostStyles
|
|
73
73
|
]; }
|
|
74
74
|
render() {
|
|
75
|
-
return html `
|
|
76
|
-
${DiscordMediaSpoileableCover.inject(this.spoiler)}
|
|
77
|
-
${when(this.accentColor, () => html `<div style=${styleMap({ 'background-color': this.accentColor })} class="discord-left-border"></div>`)}
|
|
78
|
-
<discord-components-column>
|
|
79
|
-
<slot></slot>
|
|
80
|
-
</discord-components-column>
|
|
75
|
+
return html `
|
|
76
|
+
${DiscordMediaSpoileableCover.inject(this.spoiler)}
|
|
77
|
+
${when(this.accentColor, () => html `<div style=${styleMap({ 'background-color': this.accentColor })} class="discord-left-border"></div>`)}
|
|
78
|
+
<discord-components-column>
|
|
79
|
+
<slot></slot>
|
|
80
|
+
</discord-components-column>
|
|
81
81
|
`;
|
|
82
82
|
}
|
|
83
83
|
};
|
|
@@ -30,34 +30,34 @@ let DiscordCustomEmoji = class DiscordCustomEmoji extends LitElement {
|
|
|
30
30
|
/**
|
|
31
31
|
* @internal
|
|
32
32
|
*/
|
|
33
|
-
static { this.styles = css `
|
|
34
|
-
.discord-custom-emoji {
|
|
35
|
-
display: inline-block;
|
|
36
|
-
cursor: pointer;
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
.discord-custom-emoji .discord-custom-emoji-image {
|
|
40
|
-
object-fit: contain;
|
|
41
|
-
width: 1.375em;
|
|
42
|
-
height: 1.375em;
|
|
43
|
-
vertical-align: bottom;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.discord-custom-emoji .discord-custom-jumbo-emoji-image {
|
|
47
|
-
width: 3rem;
|
|
48
|
-
height: 3rem;
|
|
49
|
-
min-height: 3rem;
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
.discord-embed-custom-emoji {
|
|
53
|
-
display: inline-block;
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
.discord-embed-custom-emoji .discord-embed-custom-emoji-image {
|
|
57
|
-
width: 18px;
|
|
58
|
-
height: 18px;
|
|
59
|
-
vertical-align: bottom;
|
|
60
|
-
}
|
|
33
|
+
static { this.styles = css `
|
|
34
|
+
.discord-custom-emoji {
|
|
35
|
+
display: inline-block;
|
|
36
|
+
cursor: pointer;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
.discord-custom-emoji .discord-custom-emoji-image {
|
|
40
|
+
object-fit: contain;
|
|
41
|
+
width: 1.375em;
|
|
42
|
+
height: 1.375em;
|
|
43
|
+
vertical-align: bottom;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.discord-custom-emoji .discord-custom-jumbo-emoji-image {
|
|
47
|
+
width: 3rem;
|
|
48
|
+
height: 3rem;
|
|
49
|
+
min-height: 3rem;
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.discord-embed-custom-emoji {
|
|
53
|
+
display: inline-block;
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.discord-embed-custom-emoji .discord-embed-custom-emoji-image {
|
|
57
|
+
width: 18px;
|
|
58
|
+
height: 18px;
|
|
59
|
+
vertical-align: bottom;
|
|
60
|
+
}
|
|
61
61
|
`; }
|
|
62
62
|
willUpdate() {
|
|
63
63
|
if (!this.url && Boolean(this.name)) {
|
|
@@ -70,21 +70,21 @@ let DiscordCustomEmoji = class DiscordCustomEmoji extends LitElement {
|
|
|
70
70
|
}
|
|
71
71
|
render() {
|
|
72
72
|
const name = `:${this.name}:`;
|
|
73
|
-
return html `<span
|
|
73
|
+
return html `<span
|
|
74
74
|
class=${classMap({
|
|
75
75
|
'discord-embed-custom-emoji': this.embedEmoji,
|
|
76
76
|
'discord-custom-emoji': !this.embedEmoji
|
|
77
|
-
})}
|
|
78
|
-
><img
|
|
79
|
-
aria-label=${name}
|
|
80
|
-
src=${ifDefined(this.url)}
|
|
81
|
-
alt=${name}
|
|
82
|
-
draggable="false"
|
|
77
|
+
})}
|
|
78
|
+
><img
|
|
79
|
+
aria-label=${name}
|
|
80
|
+
src=${ifDefined(this.url)}
|
|
81
|
+
alt=${name}
|
|
82
|
+
draggable="false"
|
|
83
83
|
class=${classMap({
|
|
84
84
|
'discord-embed-custom-emoji-image': this.embedEmoji,
|
|
85
85
|
'discord-custom-emoji-image': !this.embedEmoji,
|
|
86
86
|
'discord-custom-jumbo-emoji-image': this.jumbo
|
|
87
|
-
})}
|
|
87
|
+
})}
|
|
88
88
|
/></span> `;
|
|
89
89
|
}
|
|
90
90
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DiscordEmbed.d.ts","sourceRoot":"","sources":["../../../src/components/discord-embed/DiscordEmbed.ts"],"names":[],"mappings":"AAEA,OAAO,EAAa,UAAU,EAAE,KAAK,cAAc,EAAE,MAAM,KAAK,CAAC;AAMjE,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAExD,OAAO,+CAA+C,CAAC;AAIvD,qBACa,YAAa,SAAQ,UAAW,YAAW,UAAU;IACjE;;OAEG;IACH,gBAAgC,MAAM,0BA6NpC;IAEF;;;OAGG;IAEI,KAAK,EAAE,MAAM,CAAC;IAErB;;OAEG;IAEI,UAAU,EAAE,MAAM,CAAC;IAE1B;;OAEG;IAEI,WAAW,EAAE,MAAM,CAAC;IAE3B;;OAEG;IAEI,SAAS,EAAE,MAAM,CAAC;IAEzB;;OAEG;IAEI,UAAU,EAAE,MAAM,CAAC;IAE1B;;;;;;;;;OASG;IAEI,cAAc,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,KAAK,CAAA;KAAE,CAAM;IAErD;;OAEG;IAEI,GAAG,EAAE,MAAM,CAAC;IAEnB;;OAEG;IAEI,SAAS,EAAE,MAAM,CAAC;IAEzB;;OAEG;IAEI,KAAK,EAAE,MAAM,CAAC;IAErB;;;;;;;;;;;OAWG;IAEI,KAAK,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IAEI,QAAQ,EAAE,MAAM,CAAC;IAIjB,UAAU,UAAS;IAG1B,OAAO,CAAC,eAAe,CAAS;IAGhC,OAAO,CAAC,WAAW,CAAS;cAET,MAAM;
|
|
1
|
+
{"version":3,"file":"DiscordEmbed.d.ts","sourceRoot":"","sources":["../../../src/components/discord-embed/DiscordEmbed.ts"],"names":[],"mappings":"AAEA,OAAO,EAAa,UAAU,EAAE,KAAK,cAAc,EAAE,MAAM,KAAK,CAAC;AAMjE,OAAO,KAAK,EAAE,KAAK,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAExD,OAAO,+CAA+C,CAAC;AAIvD,qBACa,YAAa,SAAQ,UAAW,YAAW,UAAU;IACjE;;OAEG;IACH,gBAAgC,MAAM,0BA6NpC;IAEF;;;OAGG;IAEI,KAAK,EAAE,MAAM,CAAC;IAErB;;OAEG;IAEI,UAAU,EAAE,MAAM,CAAC;IAE1B;;OAEG;IAEI,WAAW,EAAE,MAAM,CAAC;IAE3B;;OAEG;IAEI,SAAS,EAAE,MAAM,CAAC;IAEzB;;OAEG;IAEI,UAAU,EAAE,MAAM,CAAC;IAE1B;;;;;;;;;OASG;IAEI,cAAc,EAAE;QAAE,CAAC,GAAG,EAAE,MAAM,GAAG,KAAK,CAAA;KAAE,CAAM;IAErD;;OAEG;IAEI,GAAG,EAAE,MAAM,CAAC;IAEnB;;OAEG;IAEI,SAAS,EAAE,MAAM,CAAC;IAEzB;;OAEG;IAEI,KAAK,EAAE,MAAM,CAAC;IAErB;;;;;;;;;;;OAWG;IAEI,KAAK,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IAEI,QAAQ,EAAE,MAAM,CAAC;IAIjB,UAAU,UAAS;IAG1B,OAAO,CAAC,eAAe,CAAS;IAGhC,OAAO,CAAC,WAAW,CAAS;cAET,MAAM;IAsFzB,OAAO,CAAC,WAAW;IA8BnB,OAAO,CAAC,UAAU;CAkClB;AAED,OAAO,CAAC,MAAM,CAAC;IACd,UAAU,qBAAqB;QAC9B,eAAe,EAAE,YAAY,CAAC;KAC9B;CACD"}
|