-
I have a really weird problem for a few months now, which I wasn't able to solve yet - maybe someone has an idea or fixed a similar problem. I built a SPA with TypeScript (4.5.4), Vue (3.2.26) and Shoelace (2.0.0-beta.62). When developing the application ( Now the problem. When building and deploying the app ( Here is an example of a comparison of both, a table with some rows having a button with an icon and a dropdown menu: This is the markup I wrote (simplified): <table class="table table-striped">
<thead>
<tr>
<th></th>
<th></th>
</tr>
</thead>
<tbody>
<tr v-for="record in objects">
<td>
<span v-if="record.email">
<sl-button type="default" label="E-Mail senden" @click="mailto(record.email)">
<sl-icon slot="prefix" name="envelope"></sl-icon>
{{ record.email }}
</sl-button>
</span>
</td>
<td>
<sl-dropdown placement="bottom-end">
<sl-button slot="trigger">
<sl-icon name="chevron-down"></sl-icon>
</sl-button>
<sl-menu class="menu">
<sl-menu-item class="menu-item" @click="openEditDialog('edit', record)">
<sl-icon slot="prefix" name="pencil"></sl-icon>
Bearbeiten
</sl-menu-item>
<sl-menu-item class="menu-item" @click="openEditDialog('clone', record)">
<sl-icon slot="prefix" name="layers"></sl-icon>
Klonen
</sl-menu-item>
<sl-divider></sl-divider>
<sl-menu-item class="menu-item danger" @click="openDeleteDialog(record)">
<sl-icon slot="prefix" name="trash"></sl-icon>
Löschen
</sl-menu-item>
</sl-menu>
</sl-dropdown>
</td>
</tr>
</tbody>
</table> When inspecting the generated markup, you'll see, that the Shoelace component was generated, but the I wasn't able to reproduce this in a CodePen yet (sorry about that), but maybe someone has an idea, why this is only happening in production? And why it only happens to icons in not-first-list-items only? Thanks for any help in advance! |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 14 replies
-
Open the dev console at the XHR tab and refresh the affected page. Are the all the icons you're using being requested? Are the responses 200 OK? I'm not seeing the base path set in the code above, so that could also be an issue (but it doesn't explain why one icon shows up, unless it's cached somehow). |
Beta Was this translation helpful? Give feedback.
-
Lit uses comments as a sort of placeholder. I don't think it's relevant to what you're seeing. Would you be able to create a minimal repro in a GitHub repo so I can take a look? |
Beta Was this translation helpful? Give feedback.
-
A similar issue was identified with tabs in #623. Adding |
Beta Was this translation helpful? Give feedback.
Lit uses comments as a sort of placeholder. I don't think it's relevant to what you're seeing.
Would you be able to create a minimal repro in a GitHub repo so I can take a look?