Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
This isn't a comprehensive doc because to our knowledge there are no OSS consumers of this lib, but for posterities sake here are the breaking changes:

### 13.2.0

- Adds support for Crossword Compiler XML files
- Makes some of the Puzzmo-y feeling linters only apply if you have split character on

### 13.1.0

- Switched the xml parsing library from xml-parser to fast-xml-parser. It may claim to be faster, but it can handle more complicated XML setups. This is mostly useful for the jpz -> xd clue parsing which should cover more cases now
Expand All @@ -12,7 +17,6 @@ This isn't a comprehensive doc because to our knowledge there are no OSS consume

- The markup has switched from some regexes to a real parser.


### 12.3.0

- Adds a CLI, see the README for examples of usage
Expand All @@ -27,7 +31,7 @@ This isn't a comprehensive doc because to our knowledge there are no OSS consume

### 12.1.0

- Adds some functions for handling importing from a Puzzleme URL. Built on code found in https://github.com/thisisparker/xword-dl and https://github.com/jpd236/kotwords
- Adds some functions for handling importing from a Puzzleme URL. Built on code found in <https://github.com/thisisparker/xword-dl> and <https://github.com/jpd236/kotwords>

### 12.0.0

Expand Down
18 changes: 15 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ There are two packages here:

### Example

Let's take this free `.puz`: https://dehodson.github.io/crossword-puzzles/crosswords/alpha-bits/
Let's take this free `.puz`: <https://dehodson.github.io/crossword-puzzles/crosswords/alpha-bits/>

Their .puz file turns into this xd:

Expand Down Expand Up @@ -4231,7 +4231,7 @@ npx xd-crossword-tools "https://puzzleme.amuselabs.com/pmm/crossword?id=abc123&s
npx xd-crossword-tools puzzle.puz "https://puzzleme.amuselabs.com/pmm/crossword?id=abc123&set=..." -o ./output
```

Supported input formats: `.puz`, `.jpz`, `.xml` (UClick), `.json` (Amuse Labs), `.txt` (Across text), and URLs which contain PuzzleMe crosswords.
Supported input formats: `.puz`, `.jpz`, `.xml` (UClick or Crossword Compiler), `.json` (Amuse Labs), `.txt` (Across text), and URLs which contain PuzzleMe crosswords.

## Import / Export

Expand Down Expand Up @@ -4283,6 +4283,18 @@ const xd = jpzToXD(jpz)

The jpz format import supports barred crosswords.

### Crossword Compiler .xml to .xd

Crossword Compiler exports XML conforming to the [`rectangular-puzzle`](https://crossword.info/xml/rectangular-puzzle.xsd) schema.

```ts
import { crossCompilerXMLToXD } from "xd-crossword-tools"

const xmlResponse = await fetch(url)
const xmlString = await xmlResponse.text()
const xd = crossCompilerXMLToXD(xmlString)
```

### Across Text (.puz.txt) to .xd

This library supports both v1 and v2 formats, including rebus cells and circled cells (MARK flag).
Expand Down Expand Up @@ -4630,7 +4642,7 @@ The `xd-crossword-tools-parser` package exports several utility functions for wo

NPM package publishing happens automatically via GitHub Actions when changes are pushed to the `main` branch. The workflow compares local package versions with published versions on npm and only publishes if versions have been bumped.

#### To Prepare a New Release:
#### To Prepare a New Release

1. **Update the changelog** (if applicable) to document changes in this release

Expand Down
Loading
Loading