```typescript
export function thawRow(row: string, steps: number): string {
  if (typeof row !== "string" || row.length === 0) {
    throw new Error("thawRow expects a non-empty string row");
  }

  const isValidChar = (char: string): boolean => char === "#" || char === ".";

  if (!row.split("").every(isValidChar)) {
    throw new Error("thawRow expects a row containing only '#' and '.'");
  }

  if (!Number.isInteger(steps) || steps < 0) {
    throw new Error("thawRow expects a non-negative integer for the number of steps");
  }

  const melted = (row: string): boolean => {
    return row[0] === "." || row[row.length - 1] === ".";
  };

  const thaw = (row: string): string => {
    let newRow = "";
    for (let i = 0; i < row.length; i++) {
      if ((i === 0 && row[i + 1] === ".") || (i === row.length - 1 && row[i - 1] === ".")) {
        newRow += ".";
      } else if (!row[i]) {
        newRow += ".";
      } else {
        newRow += "#";
      }
    }
    return newRow;
  };

  for (let i = 0; i < steps; i++) {
    row = thaw(row);
  }

  return row;
}
```