@_unit/unit 1.0.27 → 1.0.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -120,9 +120,7 @@ export class PositionObserver implements IPositionObserver {
120
120
  offset_x = offsetLeft
121
121
  offset_y = offsetTop
122
122
 
123
- const { transform } = style
124
-
125
- const { borderWidth } = getComputedStyle(element)
123
+ const { borderWidth, transform } = getComputedStyle(element)
126
124
 
127
125
  if (
128
126
  transform !== _transform ||
@@ -121,6 +121,25 @@ export function parseTransform(
121
121
  const [deg] = degt
122
122
  _rotate_z += deg
123
123
  }
124
+ break
125
+ case 'matrix':
126
+ {
127
+ const [at, bt, ct, dt, txt, tyt] = f_args_list
128
+
129
+ const [tx] = txt
130
+ const [ty] = tyt
131
+ const [a] = at
132
+ const [d] = dt
133
+
134
+ _transform_x += tx / a
135
+ _transform_y += ty / d
136
+
137
+ _scale_x *= a
138
+ _scale_y *= d
139
+
140
+ // TODO b, c
141
+ }
142
+
124
143
  break
125
144
  default:
126
145
  break