Closed amal-qb closed 1 year ago
@JosephusPaye Can you please review this PR?
Hi @amal-qb,
Thanks for the PR. Unfortately at this point I don't think the cost of this change (making a new release with a breaking change, requiring all users to update their Keen UI code) is worth it.
If you'd like to, you can create a wrapper component in your code that adjusts the API of any of the Keen UI components to suit your usage.
Here's a rough example showing the idea:
<!-- MyUiAlert.vue -->
<template>
<UiAlert :type="type" :remove-icon="removeIcon" :disable-animation="disableAnimation" :dismissible="!persist" @dismiss="$emit('dismiss')">
<slot></slot>
</UiAlert>
</template>
<script>
import { UiAlert } from "keen-ui";
export default {
name: "MyUiAlert",
components: {
UiAlert,
},
props: {
type: String,
removeIcon: Boolean,
disableAnimation: Boolean,
persist: Boolean, // Changed from `dismissible`
},
emits: ["dismiss"],
};
</script>
This PR brings one of the enhancements suggested in #468, which is changing the
dismissible
prop topersist
for theUiAlert
component.