mirror of
https://github.com/kiwix/kiwix-js-pwa.git
synced 2025-09-08 19:57:46 -04:00
Re-enabled support for using Kiwix JS Windows in the browser
This can now be run in the browser just like Kiwix JS and does not require UWP environment. Of course UWP is unaffected by this change. Former-commit-id: 5c7dc3a4010812d9d1bcf926cabfbfd278d8dc34 [formerly 96364f5624ef8793f51827f4d44bb307feb14c39] Former-commit-id: cc8ac5ad789bc11d489f14e953d0cfef9260a19a
This commit is contained in:
parent
fb9742ca4b
commit
d83d69f61a
@ -21,7 +21,7 @@
|
||||
<WindowsPhoneEmulatorID>F0AB49D8-754C-4531-A635-E6B4395FD39A;Mobile Emulator 10.0.15063.0 QHD 5.2 inch 3GB</WindowsPhoneEmulatorID>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
|
||||
<DebuggerFlavor>AppHostDeviceDebugger</DebuggerFlavor>
|
||||
<DebuggerFlavor>AppHostLocalDebugger</DebuggerFlavor>
|
||||
<WindowsPhoneEmulatorID>7C3F55B7-619D-452D-B6B0-A4A36BC552CC;Mobile Emulator 10.0.15063.0 720p 5 inch 1GB</WindowsPhoneEmulatorID>
|
||||
</PropertyGroup>
|
||||
</Project>
|
@ -7,7 +7,7 @@
|
||||
|
||||
For more information on package manifest files, see http://go.microsoft.com/fwlink/?LinkID=241727
|
||||
-->
|
||||
<Identity Name="Kiwix.KiwixJS" Version="0.8.5.0" Publisher="CN=geoff" ProcessorArchitecture="neutral" />
|
||||
<Identity Name="Kiwix.KiwixJS" Version="0.8.6.0" Publisher="CN=geoff" ProcessorArchitecture="neutral" />
|
||||
<mp:PhoneIdentity PhoneProductId="a1a5e0b9-13d4-41fb-810d-518949f03df4" PhonePublisherId="00000000-0000-0000-0000-000000000000" />
|
||||
<Properties>
|
||||
<DisplayName>Kiwix JS</DisplayName>
|
||||
@ -46,7 +46,6 @@
|
||||
<uap:FileTypeAssociation Name="zimarchive">
|
||||
<uap:DisplayName>ZIM Archive</uap:DisplayName>
|
||||
<uap:InfoTip>Compressed ZIM FIle Archive</uap:InfoTip>
|
||||
<uap:EditFlags OpenIsSafe="true" />
|
||||
<uap:SupportedFileTypes>
|
||||
<uap:FileType ContentType="application/zlib">.zim</uap:FileType>
|
||||
<uap:FileType ContentType="application/zlib">.zimaa</uap:FileType>
|
||||
@ -58,7 +57,6 @@
|
||||
</Applications>
|
||||
<Capabilities>
|
||||
<Capability Name="internetClient" />
|
||||
<uap:Capability Name="removableStorage" />
|
||||
<DeviceCapability Name="location" />
|
||||
</Capabilities>
|
||||
<build:Metadata>
|
||||
|
@ -20,19 +20,19 @@
|
||||
<WindowsSdkPath>
|
||||
</WindowsSdkPath>
|
||||
<LayoutDir>C:\Users\geoff\Source\Repos\kiwix-js-windows\bin\Release\AppX</LayoutDir>
|
||||
<RegisteredManifestChecksum>C16D189268AC138A7AEBC32F9392907DA8637CE76181AB56C8491D20A2C867E6</RegisteredManifestChecksum>
|
||||
<RegisteredPackageMoniker>Kiwix.KiwixJS_0.8.5.0_neutral__zfxmafgedzx24</RegisteredPackageMoniker>
|
||||
<RegisteredManifestChecksum>B936BD7BD91AAF32F4562C16AA473E3158195355537283D88567D6770E2F2578</RegisteredManifestChecksum>
|
||||
<RegisteredPackageMoniker>Kiwix.KiwixJS_0.8.6.0_neutral__zfxmafgedzx24</RegisteredPackageMoniker>
|
||||
<RegisteredUserModeAppID>Kiwix.KiwixJS_zfxmafgedzx24!App</RegisteredUserModeAppID>
|
||||
<RegisteredPackageID>Kiwix.KiwixJS</RegisteredPackageID>
|
||||
<RegisteredPackagePublisher>CN=geoff</RegisteredPackagePublisher>
|
||||
<RegisteredVersion>0.8.5.0</RegisteredVersion>
|
||||
<RegisteredVersion>0.8.6.0</RegisteredVersion>
|
||||
<JitOptimizationSuppressed>True</JitOptimizationSuppressed>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<AppXManifest Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\bin\Release\AppxManifest.xml">
|
||||
<PackagePath>AppxManifest.xml</PackagePath>
|
||||
<ReRegisterAppIfChanged>true</ReRegisterAppIfChanged>
|
||||
<Modified>2017-09-12T13:37:06.309</Modified>
|
||||
<Modified>2017-09-13T14:18:50.870</Modified>
|
||||
</AppXManifest>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
@ -479,7 +479,7 @@
|
||||
</AppxPackagedFile>
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\www\css\bootstrap.css">
|
||||
<PackagePath>www\css\bootstrap.css</PackagePath>
|
||||
<Modified>2017-09-09T12:51:51.410</Modified>
|
||||
<Modified>2017-09-13T12:39:31.771</Modified>
|
||||
</AppxPackagedFile>
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\www\A\dummyArticle.html">
|
||||
<PackagePath>www\A\dummyArticle.html</PackagePath>
|
||||
@ -487,7 +487,7 @@
|
||||
</AppxPackagedFile>
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\www\index.html">
|
||||
<PackagePath>www\index.html</PackagePath>
|
||||
<Modified>2017-09-11T16:17:58.025</Modified>
|
||||
<Modified>2017-09-13T13:42:11.583</Modified>
|
||||
</AppxPackagedFile>
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\www\favicon.ico">
|
||||
<PackagePath>www\favicon.ico</PackagePath>
|
||||
@ -615,7 +615,7 @@
|
||||
</AppxPackagedFile>
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\www\js\app.js">
|
||||
<PackagePath>www\js\app.js</PackagePath>
|
||||
<Modified>2017-09-12T13:20:35.297</Modified>
|
||||
<Modified>2017-09-13T14:17:09.385</Modified>
|
||||
</AppxPackagedFile>
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\www\js\init.js">
|
||||
<PackagePath>www\js\init.js</PackagePath>
|
||||
@ -1544,7 +1544,7 @@
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\bin\Release\ReverseMap\resources.pri">
|
||||
<PackagePath>resources.pri</PackagePath>
|
||||
<ReRegisterAppIfChanged>true</ReRegisterAppIfChanged>
|
||||
<Modified>2017-09-12T11:20:34.442</Modified>
|
||||
<Modified>2017-09-13T14:18:50.544</Modified>
|
||||
</AppxPackagedFile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
|
2
bin/Release/AppX/www/css/bootstrap.css
vendored
2
bin/Release/AppX/www/css/bootstrap.css
vendored
@ -1,4 +1,4 @@
|
||||
/*!
|
||||
/*!
|
||||
* bootswatch v3.3.7
|
||||
* Homepage: http://bootswatch.com
|
||||
* Copyright 2012-2017 Thomas Park
|
||||
|
@ -275,12 +275,18 @@
|
||||
<p>This application needs a ZIM archive to work. You can get one from the <a href="#downloads">download links panel</a>.</p>
|
||||
</div>
|
||||
<div id="openLocalFiles" style="display: none;">
|
||||
<div class="row">
|
||||
<div id="UWPInstructions" class="row">
|
||||
<p>
|
||||
If you have a single (unsplit) ZIM archive, use the <b>first</b> button.<br />
|
||||
For a split archive (.zimaa, .zimab, etc.) or multiple archives, use the <b>second</b> button.
|
||||
</p>
|
||||
</div>
|
||||
<div id="instructions" class="row" style="display:none;">
|
||||
<p>
|
||||
Please choose the location of your ZIM archive.<br />
|
||||
For a split archive (.zimaa, .zimab, etc.) you must select <b>all</b> the split parts.
|
||||
</p>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-6">
|
||||
<input type="button" class="btn btn-primary" value="Select single archive" id="archiveFile" accept=".zim" />
|
||||
|
@ -429,6 +429,15 @@ define(['jquery', 'zimArchiveLoader', 'util', 'uiUtil', 'cookies', 'abstractFile
|
||||
if (params.localStorage && !params.pickedFolder && !params.pickedFile) {
|
||||
params.pickedFolder = params.localStorage;
|
||||
}
|
||||
if (typeof Windows === 'undefined') {
|
||||
//If not UWP, display legacy File Select
|
||||
document.getElementById('archiveFile').style.display = "none";
|
||||
document.getElementById('archiveFiles').style.display = "none";
|
||||
document.getElementById('UWPInstructions').style.display = "none";
|
||||
document.getElementById('instructions').style.display = "inline";
|
||||
document.getElementById('archiveFilesLegacy').style.display = "inline";
|
||||
$('#archiveFilesLegacy').on('change', setLocalArchiveFromFileSelect)
|
||||
}
|
||||
return false;
|
||||
});
|
||||
$('#btnAbout').on('click', function (e) {
|
||||
@ -1124,6 +1133,10 @@ define(['jquery', 'zimArchiveLoader', 'util', 'uiUtil', 'cookies', 'abstractFile
|
||||
*/
|
||||
function displayFileSelect() {
|
||||
$('#openLocalFiles').show();
|
||||
if (typeof Windows === 'undefined') {
|
||||
//If not UWP, display legacy File Select
|
||||
$('#btnConfigure').click();
|
||||
}
|
||||
//TODO - check if this is necessary or if it causes the archiveList change event to fire
|
||||
//Make archive list combo box fit the number of files
|
||||
//var comboArchiveList = document.getElementById('archiveList');
|
||||
@ -1221,7 +1234,7 @@ define(['jquery', 'zimArchiveLoader', 'util', 'uiUtil', 'cookies', 'abstractFile
|
||||
* Sets the localArchive from the File selects populated by user
|
||||
*/
|
||||
function setLocalArchiveFromFileSelect() {
|
||||
setLocalArchiveFromFileList(document.getElementById('archiveFiles').files);
|
||||
setLocalArchiveFromFileList(document.getElementById('archiveFilesLegacy').files);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1165,7 +1165,7 @@
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\www\js\MathJax\extensions\a11y\mathmaps\.htaccess">
|
||||
<PackagePath>www\js\MathJax\extensions\a11y\mathmaps\.htaccess</PackagePath>
|
||||
</AppxPackagedFile>
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\bin\Release\resources.pri">
|
||||
<AppxPackagedFile Include="C:\Users\geoff\Source\Repos\kiwix-js-windows\bin\Release\ReverseMap\resources.pri">
|
||||
<PackagePath>resources.pri</PackagePath>
|
||||
<ReRegisterAppIfChanged>true</ReRegisterAppIfChanged>
|
||||
</AppxPackagedFile>
|
||||
|
Binary file not shown.
@ -46,4 +46,4 @@ C:\Users\geoff\Source\Repos\kiwix-js-windows\bld\Release\qualifiers.txt.intermed
|
||||
C:\Users\geoff\Source\Repos\kiwix-js-windows\bld\Release\MultipleQualifiersPerDimensionFound.txt
|
||||
C:\Users\geoff\Source\Repos\kiwix-js-windows\bld\Release\ProjectArchitectures.txt
|
||||
C:\Users\geoff\Source\Repos\kiwix-js-windows\bld\Release\KiwixWebApp.jsproj.CoreCompileInputs.cache
|
||||
C:\Users\geoff\Source\Repos\kiwix-js-windows\bin\Release\resources.pri
|
||||
C:\Users\geoff\Source\Repos\kiwix-js-windows\bin\Release\ReverseMap\resources.pri
|
||||
|
@ -275,12 +275,18 @@
|
||||
<p>This application needs a ZIM archive to work. You can get one from the <a href="#downloads">download links panel</a>.</p>
|
||||
</div>
|
||||
<div id="openLocalFiles" style="display: none;">
|
||||
<div class="row">
|
||||
<div id="UWPInstructions" class="row">
|
||||
<p>
|
||||
If you have a single (unsplit) ZIM archive, use the <b>first</b> button.<br />
|
||||
For a split archive (.zimaa, .zimab, etc.) or multiple archives, use the <b>second</b> button.
|
||||
</p>
|
||||
</div>
|
||||
<div id="instructions" class="row" style="display:none;">
|
||||
<p>
|
||||
Please choose the location of your ZIM archive.<br />
|
||||
For a split archive (.zimaa, .zimab, etc.) you must select <b>all</b> the split parts.
|
||||
</p>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-xs-6">
|
||||
<input type="button" class="btn btn-primary" value="Select single archive" id="archiveFile" accept=".zim" />
|
||||
|
@ -429,6 +429,15 @@ define(['jquery', 'zimArchiveLoader', 'util', 'uiUtil', 'cookies', 'abstractFile
|
||||
if (params.localStorage && !params.pickedFolder && !params.pickedFile) {
|
||||
params.pickedFolder = params.localStorage;
|
||||
}
|
||||
if (typeof Windows === 'undefined') {
|
||||
//If not UWP, display legacy File Select
|
||||
document.getElementById('archiveFile').style.display = "none";
|
||||
document.getElementById('archiveFiles').style.display = "none";
|
||||
document.getElementById('UWPInstructions').style.display = "none";
|
||||
document.getElementById('instructions').style.display = "inline";
|
||||
document.getElementById('archiveFilesLegacy').style.display = "inline";
|
||||
$('#archiveFilesLegacy').on('change', setLocalArchiveFromFileSelect)
|
||||
}
|
||||
return false;
|
||||
});
|
||||
$('#btnAbout').on('click', function (e) {
|
||||
@ -1124,6 +1133,10 @@ define(['jquery', 'zimArchiveLoader', 'util', 'uiUtil', 'cookies', 'abstractFile
|
||||
*/
|
||||
function displayFileSelect() {
|
||||
$('#openLocalFiles').show();
|
||||
if (typeof Windows === 'undefined') {
|
||||
//If not UWP, display legacy File Select
|
||||
$('#btnConfigure').click();
|
||||
}
|
||||
//TODO - check if this is necessary or if it causes the archiveList change event to fire
|
||||
//Make archive list combo box fit the number of files
|
||||
//var comboArchiveList = document.getElementById('archiveList');
|
||||
@ -1221,7 +1234,7 @@ define(['jquery', 'zimArchiveLoader', 'util', 'uiUtil', 'cookies', 'abstractFile
|
||||
* Sets the localArchive from the File selects populated by user
|
||||
*/
|
||||
function setLocalArchiveFromFileSelect() {
|
||||
setLocalArchiveFromFileList(document.getElementById('archiveFiles').files);
|
||||
setLocalArchiveFromFileList(document.getElementById('archiveFilesLegacy').files);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user