Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/develop' into dropdown/combobox
Browse files Browse the repository at this point in the history
  • Loading branch information
mlmoravek committed Jan 31, 2025
1 parent 00e71df commit 48987a5
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ const selected = ref(options[3].value);
const groupOptions: OptionsPropWithGroups<string> = [
{
group: "Black Sails",
label: "Black Sails",
attrs: { disabled: true },
options: [
{ label: "Flint", value: "flint" },
Expand All @@ -209,7 +209,7 @@ const groupOptions: OptionsPropWithGroups<string> = [
],
},
{
group: "Breaking Bad",
label: "Breaking Bad",
attrs: { disabled: true },
options: {
heisenberg: "Heisenberg",
Expand All @@ -219,7 +219,7 @@ const groupOptions: OptionsPropWithGroups<string> = [
},
},
{
group: "Game of Thrones",
label: "Game of Thrones",
attrs: { disabled: true },
options: [
"Tyrion Lannister",
Expand Down
6 changes: 0 additions & 6 deletions packages/oruga/src/components/dropdown/DropdownItem.vue
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,3 @@ const rootClasses = defineClasses(
<slot>{{ label }}</slot>
</component>
</template>

<style>
.o-drop__item--focused {
background-color: gray;
}
</style>
6 changes: 3 additions & 3 deletions packages/oruga/src/components/dropdown/examples/options.vue
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const selected = ref<string>();
const groupOptions: OptionsPropWithGroups<string> = [
{
group: "Black Sails",
label: "Black Sails",
attrs: { disabled: true },
options: [
{ label: "Flint", value: "flint" },
Expand All @@ -24,7 +24,7 @@ const groupOptions: OptionsPropWithGroups<string> = [
],
},
{
group: "Breaking Bad",
label: "Breaking Bad",
attrs: { disabled: true },
options: {
heisenberg: "Heisenberg",
Expand All @@ -34,7 +34,7 @@ const groupOptions: OptionsPropWithGroups<string> = [
},
},
{
group: "Game of Thrones",
label: "Game of Thrones",
attrs: { disabled: true },
options: [
"Tyrion Lannister",
Expand Down
3 changes: 0 additions & 3 deletions packages/oruga/src/components/dropdown/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,3 @@ export type DropdownItemComponent<T> = DropdownItemProps<T> & {
};

export type DropdownChildItem<T> = ProviderItem<DropdownItemComponent<T>>;

// export type DropdownItem<T> = Omit<ProviderItem, "data"> &
// DropdownItemComponent<T>;
8 changes: 4 additions & 4 deletions packages/oruga/src/composables/useInfiniteScroll.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import { isClient } from "@/utils/ssr";
import type { Component, MaybeRefOrGetter } from "vue";
import { useEventListener } from "./useEventListener";
import type { MaybeRefOrGetter } from "vue";
import { useEventListener, type EventTarget } from "./useEventListener";
import { unrefElement } from "./unrefElement";

export function useInfiniteScroll(
elementRef: MaybeRefOrGetter<HTMLElement | Component | undefined>,
elementRef: MaybeRefOrGetter<EventTarget>,
onEnd: () => void,
onStart: () => void,
): { checkScroll: () => void } {
if (isClient) useEventListener("scroll", checkScroll, elementRef);
if (isClient) useEventListener(elementRef, "scroll", checkScroll);

/** Check if the scroll list inside the dropdown reached the top or it's end. */
function checkScroll(): void {
Expand Down

0 comments on commit 48987a5

Please sign in to comment.