MVFv3 API Documentation
    Preparing search index...

    Type Alias DefaultStyleCollection

    DefaultStyleCollection: {
        [key: string]: {
            geometryAnchors: { floorId: `f_${string}`; geometryId: `g_${string}` }[];
        } & { extra?: { [key: string]: unknown } } & {
            altitude: number;
            buffer: number;
            color: string;
            height: number;
            opacity: number;
            hidden?: boolean;
        };
    }

    A record of style tokens to DefaultStyle objects.

    The style token is NOT expected to be user facing, and will NOT be localized. It is also NOT guaranteed to be durable between different versions of the MVF.

    Type declaration

    • [key: string]: { geometryAnchors: { floorId: `f_${string}`; geometryId: `g_${string}` }[] } & {
          extra?: { [key: string]: unknown };
      } & {
          altitude: number;
          buffer: number;
          color: string;
          height: number;
          opacity: number;
          hidden?: boolean;
      }

      Type declaration

      • geometryAnchors: { floorId: `f_${string}`; geometryId: `g_${string}` }[]
      • Optionalextra?: { [key: string]: unknown }

        {@inheritDoc utility-types/extra!Extra}

        Extra

      • altitude: number

        How far off the bottom of the floor the objects with this style should be drawn at, in meters. This is permitted to be negative, so applications that respect default styles will need to choose how this field is interpreted.

      • buffer: number

        The buffer amount to apply to the geometry, in meters. This can be used to inflate line string geometry for walls, but might also be applicable as a way to grow or shrink polygon geometry for aesthetic purposes. Can be negative. Behaviour is undefined if the buffer amount is negative and exceeds the geometry's dimensions when applied, however applications should likely choose not to draw the geometry in question.

      • color: string

        Color should be represented with a hash (#), followed by 6 hexadecimal digits. ex: #RRGGBB

        ^#[0-9a-fA-F]{6}$

      • height: number

        The height of the objects belonging to this layer, in meters.

        0

      • opacity: number

        0

        1

      • Optionalhidden?: boolean

        Whether or not the objects with this style should be hidden from view. This is generally preferred over setting opacity to 0 to handle cases where an application may force this geometry to be rendered, as this is simply a hint. If unspecified, the default behaviour is to have the geometry visible.