Skip to content
Discussion options

You must be logged in to vote

Here's a react example you can convert to Vue.

The trick is to use the updatePosition prop of the positioner to set a data-fullscreen attribute then use css to style that attribute as needed.

https://stackblitz.com/edit/lcso13hl?file=src%2FApp.tsx

import { Portal } from '@ark-ui/react/portal';
import { Select, createListCollection } from '@ark-ui/react/select';
import { ChevronDownIcon } from 'lucide-react';
import { useRef } from 'react';

const dataAttr = (el: HTMLElement, key: string, value: boolean) => {
  if (value) el.dataset[key] = '';
  else delete el.dataset[key];
};

const isMdDown = () => window.matchMedia('(max-width: 640px)').matches;

export const App = () => {
  const colle…

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by segunadebayo
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants