// Copyright (c) 2020-2022 MathJax Consortium
// SPDX-License-Identifier: Apache-2.0
// Sources: ts/input/tex/mathtools/MathtoolsMethods.ts (MtLap), ParseUtil.ts.

package tex

import 

func ( *parser) ( string) ([]*mml.Node, error) {
	// GetArgument starts with GetNext's JavaScript whitespace. This boundary
	// is separate from the whitespace interpreted inside the captured text.
	for .pos < len(.source) && internalTextSpace(.peekRune()) {
		.consumeRune()
	}
	, ,  := .readArgumentAtCursor(, false)
	if  != nil {
		return nil, 
	}
	,  := .internalMath(, "", true)
	if  != nil {
		return nil, 
	}
	 := setAttributes(node("mpadded", ...), map[string]any{"width": 0})
	switch  {
	case "textllap":
		.Attributes.Set("lspace", "-1width")
	case "clap", "textclap":
		.Attributes.Set("lspace", "-.5width")
	}
	// MtLap pushes the padded box itself, unlike the mathematical Lap
	// handlers, which add a TeXAtom.
	return []*mml.Node{}, nil
}