node-sword-interface 1.0.38 → 1.0.39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/index.js
CHANGED
|
@@ -331,6 +331,14 @@ class NodeSwordInterface {
|
|
|
331
331
|
return this.nativeInterface.enableMarkup();
|
|
332
332
|
}
|
|
333
333
|
|
|
334
|
+
/**
|
|
335
|
+
* Disable available markup (like Strongs, foot notes, etc.)
|
|
336
|
+
* This influences the output for getChapterText, getBookText and getBibleText.
|
|
337
|
+
*/
|
|
338
|
+
disableMarkup() {
|
|
339
|
+
return this.nativeInterface.disableMarkup();
|
|
340
|
+
}
|
|
341
|
+
|
|
334
342
|
/**
|
|
335
343
|
* Enables rendering of Strongs elements with non-breaking spaces.
|
|
336
344
|
*/
|
package/package.json
CHANGED
|
@@ -90,6 +90,7 @@ Napi::Object NodeSwordInterface::Init(Napi::Env env, Napi::Object exports)
|
|
|
90
90
|
InstanceMethod("getModuleDescription", &NodeSwordInterface::getModuleDescription),
|
|
91
91
|
InstanceMethod("getLocalModule", &NodeSwordInterface::getLocalModule),
|
|
92
92
|
InstanceMethod("enableMarkup", &NodeSwordInterface::enableMarkup),
|
|
93
|
+
InstanceMethod("disableMarkup", &NodeSwordInterface::disableMarkup),
|
|
93
94
|
InstanceMethod("enableStrongsWithNbsp", &NodeSwordInterface::enableStrongsWithNbsp),
|
|
94
95
|
InstanceMethod("getRawModuleEntry", &NodeSwordInterface::getRawModuleEntry),
|
|
95
96
|
InstanceMethod("getReferenceText", &NodeSwordInterface::getReferenceText),
|
|
@@ -527,6 +528,16 @@ Napi::Value NodeSwordInterface::enableMarkup(const Napi::CallbackInfo& info)
|
|
|
527
528
|
return info.Env().Undefined();
|
|
528
529
|
}
|
|
529
530
|
|
|
531
|
+
Napi::Value NodeSwordInterface::disableMarkup(const Napi::CallbackInfo& info)
|
|
532
|
+
{
|
|
533
|
+
lockApi();
|
|
534
|
+
Napi::Env env = info.Env();
|
|
535
|
+
Napi::HandleScope scope(env);
|
|
536
|
+
this->_textProcessor->disableMarkup();
|
|
537
|
+
unlockApi();
|
|
538
|
+
return info.Env().Undefined();
|
|
539
|
+
}
|
|
540
|
+
|
|
530
541
|
Napi::Value NodeSwordInterface::enableStrongsWithNbsp(const Napi::CallbackInfo& info)
|
|
531
542
|
{
|
|
532
543
|
lockApi();
|
|
@@ -70,6 +70,7 @@ private:
|
|
|
70
70
|
Napi::Value getLocalModule(const Napi::CallbackInfo& info);
|
|
71
71
|
|
|
72
72
|
Napi::Value enableMarkup(const Napi::CallbackInfo& info);
|
|
73
|
+
Napi::Value disableMarkup(const Napi::CallbackInfo& info);
|
|
73
74
|
Napi::Value enableStrongsWithNbsp(const Napi::CallbackInfo& info);
|
|
74
75
|
|
|
75
76
|
Napi::Value getRawModuleEntry(const Napi::CallbackInfo& info);
|