Repository: sveltejs/svelte
File: packages/svelte/src/compiler/errors.js (JavaScript)

Code before:

/**
 * A :global {...} block cannot be part of a selector list with more than one item
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_block_invalid_list(node) {
	e(node, "css_global_block_invalid_list", "A :global {...} block cannot be part of a selector list with more than one item");
}

/**
 * A :global {...} block cannot modify an existing selector
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_block_invalid_modifier(node) {
	e(node, "css_global_block_invalid_modifier", "A :global {...} block cannot modify an existing selector");
}

/**
 * :global(...) can be at the start or end of a selector sequence, but not in the middle
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_invalid_placement(node) {
	e(node, "css_global_invalid_placement", ":global(...) can be at the start or end of a selector sequence, but not in the middle");
}

/**
 * :global(...) must contain exactly one selector
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_invalid_selector(node) {
	e(node, "css_global_invalid_selector", ":global(...) must contain exactly one selector");
}

/**
 * :global(...) must not contain type or universal selectors when used in a compound selector
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_invalid_selector_list(node) {
	e(node, "css_global_invalid_selector_list", ":global(...) must not contain type or universal selectors when used in a compound selector");
}

/**
 * Nesting selectors can only be used inside a rule
 * @param {null | number | NodeLike} node
 * @returns {never}
 */

Review comment (suggestion):
```suggestion
	e(node, "css_global_block_invalid_placement", "A `:global {...}` block can only appear at the end of a selector sequence (did you mean to use `:global(...)` instead?)");
```

Code after:

/**
 * A :global {...} block cannot be part of a selector list with more than one item
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_block_invalid_list(node) {
	e(node, "css_global_block_invalid_list", "A :global {...} block cannot be part of a selector list with more than one item");
}

/**
 * A :global {...} block cannot modify an existing selector
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_block_invalid_modifier(node) {
	e(node, "css_global_block_invalid_modifier", "A :global {...} block cannot modify an existing selector");
}

/**
 * A :global {...} block can only appear at the end of a selector sequence (did you mean to use :global(...) instead?)
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_block_invalid_placement(node) {
	e(node, "css_global_block_invalid_placement", "A :global {...} block can only appear at the end of a selector sequence (did you mean to use :global(...) instead?)");
}

/**
 * :global(...) can be at the start or end of a selector sequence, but not in the middle
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_invalid_placement(node) {
	e(node, "css_global_invalid_placement", ":global(...) can be at the start or end of a selector sequence, but not in the middle");
}

/**
 * :global(...) must contain exactly one selector
 * @param {null | number | NodeLike} node
 * @returns {never}
 */
export function css_global_invalid_selector(node) {
	e(node, "css_global_invalid_selector", ":global(...) must contain exactly one selector");
}

/**
 * :global(...) must not contain type or universal selectors when used in a compound selector
 * @param {null | number | NodeLike} node
 * @returns {never}
 */