=== Neutrope Quiz Engine ===
Contributors: neutropeinc
Tags: quiz, exam, test, questions, e-learning
Requires at least: 5.8
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 0.4.5
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Create certification quizzes and practice tests in WordPress with question banks, shortcodes, instant scoring, and explanations.

== Description ==

**Neutrope Quiz Engine** is a flexible quiz engine for WordPress, designed for
certification study sites, e-learning, and media sites that want to embed
interactive quizzes. Build a library of questions and one or more test sets in
the WordPress admin, then drop a shortcode anywhere — on pages, posts, or
custom content — to render the quiz. Scoring happens entirely on the client,
so quizzes work on cached / static pages and do not write to the database.

= Core features =

* Questions and test sets managed as WordPress custom post types
* Practice mode (per-question feedback) and mock mode (graded at the end)
* Step-by-step or full-list display
* Question shuffling, choice shuffling, configurable choice labels (A/B/C/D,
  カナ, numeric, custom)
* Pass thresholds (% or score) and per-set time limit with countdown
* Question banks (practice / mock / 過去問 etc.) for grouped delivery
* Per-field accuracy breakdown on the results screen
* CSV import with dry-run, upsert and automatic term creation
* Configurable call-to-action link per test set on the result screen

= Shortcodes =

* `[ntqengine_quiz set="<ID>"]` — renders the test set with the given ID.

Example: `[ntqengine_quiz set="123"]`

= No external services =

All processing happens inside your WordPress install. The plugin makes no
outbound HTTP requests, loads no remote scripts or styles, and stores no
quiz-result records in the database.

== Installation ==

1. Upload the plugin folder to `/wp-content/plugins/`, or install through the
   WordPress *Plugins* screen.
2. Activate **Neutrope Quiz Engine** through the *Plugins* menu in WordPress.
3. Under the *問題* menu, add some questions. Under the *テストセット* menu,
   create a test set and link it to the relevant *資格種別* taxonomy term.
4. Embed the test set anywhere with `[ntqengine_quiz set="<ID>"]`.

CSV import is available under *問題 → CSVインポート* (dry-run + upsert).

== Frequently Asked Questions ==

= Does the plugin store quiz results in the database? =

No. Scoring is computed entirely on the client and is not persisted. Pages
can be safely cached because no per-user state is written on the server.

= What is removed on uninstall? =

Only the CSV-import temporary transients and the
`wp-content/uploads/ntqengine-imports/` working directory. Questions, test
sets, taxonomy terms and post meta are deliberately preserved so production
data is never lost on uninstall.

= Is the plugin translation-ready? =

Yes. All user-facing strings (PHP and JS) are routed through the
`neutrope-quiz-engine` text domain. A `languages/neutrope-quiz-engine.pot` template is
included. JS strings are delivered via `wp_localize_script`, with Japanese
fallbacks compiled into the script so display never breaks when translations
are missing.

= Does it work with cache plugins? =

Yes. Output is purely HTML plus a JSON-in-`<script>` payload; nothing depends
on per-request server state. Page caches (WP Super Cache, W3 Total Cache,
LiteSpeed, etc.) are safe.

= Which shortcode should I use? =

Use `[ntqengine_quiz set="<ID>"]`. It is the only shortcode the plugin
registers. You can place several instances on the same page; each one renders
and scores independently.

== Screenshots ==

1. Quiz display on the front end (practice mode, step-by-step).
2. Result screen with score, accuracy, pass / fail verdict and per-field
   breakdown.
3. Question admin: choices, correct answer, explanation and difficulty.
4. Test set admin: mode, question count, time limit, pass mode, CTA and
   display options.
5. CSV import: dry-run report with per-row create / update / skip / error
   counts.

== Changelog ==

= 0.4.5 =
* Prefix compliance update for WordPress.org: renamed the shortcode, custom
  post types, taxonomies, script/style handle, JavaScript object, plugin
  constants and the CSV-import transient/admin identifiers to the unique
  `ntqengine` prefix.
* The shortcode is now `[ntqengine_quiz set="<ID>"]`. The previous
  `[nqe_quiz]`, `[ql_quiz]` and `[wpqe_quiz]` aliases have been removed.
* Existing content created with earlier versions needs to be migrated to the
  new post types and taxonomies before upgrading.

= 0.4.4 =
* Add browser-local anonymous quiz summary support for future Study Desk integrations when Pro integration data is available.
* Keep quiz summary storage client-side and scoped to the visitor's browser.

= 0.4.3 =
* Pass completed quiz result payloads to the Pro integration bridge when available.
* Preserve existing quiz scoring, retry, and scroll behavior.

= 0.4.2 =
* Fix scroll position after viewing quiz results and retrying a quiz.
* Preserve the quiz completed JavaScript event hook for Pro integrations.

= 0.4.1 =
* Added a `nqe:quiz:completed` JavaScript event, dispatched on the quiz root
  element (`.skl-quiz`, with `bubbles: true`) when scoring completes. This is a
  purely additive extension point for add-ons such as Neutrope Quiz Engine Pro;
  it does not change existing shortcodes, markup, CSS, scoring logic, the result
  display, or any backward-compatibility identifiers. Scoring still happens
  entirely on the client and no data is written to the database by the free
  plugin.

= 0.4.0 =
* Initial public release.
* Question and test-set custom post types with practice and mock modes,
  step / list display, question and choice shuffling, configurable choice
  labels, pass thresholds, countdown timer, question banks, per-field
  accuracy breakdown, and a configurable per-set CTA on the result screen.
* CSV importer with dry-run, upsert, automatic term creation and
  CSRF-hardened upload handling.
* Shortcode for embedding a test set on any page or post.
* Frontend strings routed through `wp_localize_script` with Japanese
  fallbacks (translation-ready via the `neutrope-quiz-engine` text domain).
* No outbound HTTP, no external assets, no per-user database writes.

== Upgrade Notice ==

= 0.4.5 =
Breaking change: the shortcode, post types, taxonomies, handles and constants now use the unique `ntqengine` prefix, and `[nqe_quiz]` / `[ql_quiz]` / `[wpqe_quiz]` are removed. Use `[ntqengine_quiz set="<ID>"]` and migrate existing content before upgrading.

= 0.4.4 =
Adds browser-local anonymous quiz summary support for future Study Desk integrations when Pro integration data is available.

= 0.4.3 =
Improves the quiz-completed JavaScript event payload for future Pro integrations.

= 0.4.2 =
Fixes the page scroll position after viewing results and retrying a quiz. No breaking changes.

= 0.4.1 =
Adds the `nqe:quiz:completed` JavaScript extension event. No breaking changes.

= 0.4.0 =
Initial release of Neutrope Quiz Engine.
