MCPcopy Create free account
hub / github.com/Graphify-Labs/graphify / cases_e

Function cases_e

scripts/theme_gate.py:355–372  ·  view source on GitHub ↗
(root: Path)

Source from the content-addressed store, hash-verified

353
354
355def cases_e(root: Path) -> list[Case]:
356 defined = _css_defined_classes(root)
357 out: list[Case] = []
358 for p in _liquid_files(root):
359 masked = mask_inactive(_read(p))
360 view_chars = list(masked)
361 for sp in _LIQUID_SPAN.finditer(masked):
362 _blank(masked, sp.start(), sp.end(), view_chars)
363 view = "".join(view_chars)
364 ln = _Lines(view)
365 rel = _rel(root, p)
366 for am in _CLASS_ATTR.finditer(view):
367 base = am.start(2)
368 for tm in _CLASS_TOKEN.finditer(am.group(2)):
369 tok = tm.group(0)
370 if _VALID_TOKEN.match(tok) and f".{tok}" in defined:
371 out.append((rel, ln.of(base + tm.start()), f".{tok}"))
372 return out
373
374
375# --------------------------------------------------------------- definitions

Callers 1

measureFunction · 0.85

Calls 10

_css_defined_classesFunction · 0.85
_liquid_filesFunction · 0.85
mask_inactiveFunction · 0.85
_LinesClass · 0.85
ofMethod · 0.80
_readFunction · 0.70
_blankFunction · 0.70
_relFunction · 0.70
startMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected