Skip to content

Commit

Permalink
Merge pull request #400 from ownego/fix/index-table-sticky-header
Browse files Browse the repository at this point in the history
Fix/index table sticky header
  • Loading branch information
juzser authored Sep 6, 2024
2 parents 341b464 + 2252e6e commit dea0a05
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/components/IndexTable/IndexTableBase.vue
Original file line number Diff line number Diff line change
Expand Up @@ -596,7 +596,7 @@ function handleSortHeadingClick(
// loadingMarkup
const loadingMarkup = computed(() => {
return h(
return loading?.value && h(
'div',
{
class: classNames(
Expand Down
5 changes: 3 additions & 2 deletions src/components/Sticky/Sticky.vue
Original file line number Diff line number Diff line change
Expand Up @@ -66,15 +66,16 @@ const handlePositioning = (
width = 0,
) => {
if ((stick && !isSticky.value) || (!stick && isSticky.value)) {
adjustPlaceHolderNode(stick);
isSticky.value = !isSticky.value;
emits('sticky-change', isSticky.value);
emits('sticky-change', !isSticky.value);
if (!props.boundingElement) {
return;
}
adjustPlaceHolderNode(stick);
props.boundingElement.toggleAttribute('data-sticky-active');
}
style.value = stick
Expand Down
5 changes: 2 additions & 3 deletions src/utilities/types.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
import type { Component } from 'vue';
import type { ComputedRef, Ref } from 'vue';
import type { Component, ComputedRef, Ref } from 'vue';

export type Target = '_blank' | '_self' | '_parent' | '_top';

export type IconSource = Component | string | (string | Component)[]

export type VueNode = string | number | boolean | Component | Element | null | undefined;
export type VueNode = string | number | boolean | Component | Element | Function | null | undefined;

export type NonEmptyArray<T> = [T, ...T[]];

Expand Down

0 comments on commit dea0a05

Please sign in to comment.