/**
 * @license
 * Copyright 2023 Tyler Technologies, Inc. 
 * License: Apache-2.0
 */
import { getShadowElement } from '@tylertech/forge-core';
import { BaseAdapter } from '../core/base/base-adapter';
import { STACK_CONSTANTS } from './stack-constants';
export class StackAdapter extends BaseAdapter {
    constructor(component) {
        super(component);
        this._rootElement = getShadowElement(component, STACK_CONSTANTS.selectors.ROOT);
    }
    setGap(gap) {
        const value = /^\d+$/.test(gap) ? `${gap}px` : gap;
        this._rootElement.style.gap = `var(--forge-stack-gap, ${value})`;
    }
}
