Skip to content

Commit

Permalink
Add support for Markdown and code previews
Browse files Browse the repository at this point in the history
  • Loading branch information
samuelmeuli committed Mar 5, 2020
1 parent ea5c02d commit f24e1c8
Show file tree
Hide file tree
Showing 16 changed files with 782 additions and 37 deletions.
121 changes: 116 additions & 5 deletions Glance.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,21 +3,31 @@
archiveVersion = 1;
classes = {
};
objectVersion = 50;
objectVersion = 52;
objects = {

/* Begin PBXBuildFile section */
7E1DC515240E5A4B00D0A061 /* shared.css in Resources */ = {isa = PBXBuildFile; fileRef = 7E1DC50A240E5A4B00D0A061 /* shared.css */; };
7E1DC51F240E6CE300D0A061 /* Renderer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7E1DC51E240E6CE300D0A061 /* Renderer.swift */; };
7E1DC521240E6D8000D0A061 /* MarkdownRenderer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7E1DC520240E6D8000D0A061 /* MarkdownRenderer.swift */; };
7E1DC524240E6DCD00D0A061 /* Down in Frameworks */ = {isa = PBXBuildFile; productRef = 7E1DC523240E6DCD00D0A061 /* Down */; };
7E1DC528240E6F4A00D0A061 /* RendererFactory.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7E1DC527240E6F4A00D0A061 /* RendererFactory.swift */; };
7E1DC52A240E6FDE00D0A061 /* CodeRenderer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7E1DC529240E6FDE00D0A061 /* CodeRenderer.swift */; };
7E35BFC12410F60F00AB0A3C /* prism.min.css in Resources */ = {isa = PBXBuildFile; fileRef = 7E35BFBF2410F60F00AB0A3C /* prism.min.css */; };
7E35BFC22410F60F00AB0A3C /* prism.min.js in Resources */ = {isa = PBXBuildFile; fileRef = 7E35BFC02410F60F00AB0A3C /* prism.min.js */; };
7E35BFC42410FDD800AB0A3C /* minireset.min.css in Resources */ = {isa = PBXBuildFile; fileRef = 7E35BFC32410FDD800AB0A3C /* minireset.min.css */; };
7E59DDD7240CC3B2009A4E05 /* .gitignore in Resources */ = {isa = PBXBuildFile; fileRef = 7E59DDD6240CC3B2009A4E05 /* .gitignore */; };
7E6EF1FD240CC802009E4199 /* Quartz.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 7E6EF1FC240CC802009E4199 /* Quartz.framework */; };
7E6EF200240CC802009E4199 /* PreviewViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7E6EF1FF240CC802009E4199 /* PreviewViewController.swift */; };
7E6EF208240CC802009E4199 /* QLPlugin.appex in Embed App Extensions */ = {isa = PBXBuildFile; fileRef = 7E6EF1FA240CC802009E4199 /* QLPlugin.appex */; settings = {ATTRIBUTES = (RemoveHeadersOnCopy, ); }; };
7E8DEE96240CC47C007A1477 /* .swiftformat in Resources */ = {isa = PBXBuildFile; fileRef = 7E8DEE94240CC47B007A1477 /* .swiftformat */; };
7E8DEE97240CC47C007A1477 /* .swiftlint.yml in Resources */ = {isa = PBXBuildFile; fileRef = 7E8DEE95240CC47B007A1477 /* .swiftlint.yml */; };
7E8DEE99240CC4D2007A1477 /* GlanceApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7E8DEE98240CC4D2007A1477 /* GlanceApp.swift */; };
7EAC01EA240D2063009505D0 /* PreviewWebView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7EAC01E9240D2063009505D0 /* PreviewWebView.swift */; };
7EAC01EC240D220B009505D0 /* FileInfo.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7EAC01EB240D220B009505D0 /* FileInfo.swift */; };
7ECC8CF2240CB4CC000D6970 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7ECC8CF1240CB4CC000D6970 /* AppDelegate.swift */; };
7ECC8CF4240CB4CC000D6970 /* ViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = 7ECC8CF3240CB4CC000D6970 /* ViewController.swift */; };
7ECC8CF6240CB4CC000D6970 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 7ECC8CF5240CB4CC000D6970 /* Assets.xcassets */; };
7ECE2C69240CF317001711C7 /* content.html in Resources */ = {isa = PBXBuildFile; fileRef = 7ECE2C68240CF317001711C7 /* content.html */; };
/* End PBXBuildFile section */

/* Begin PBXContainerItemProxy section */
Expand Down Expand Up @@ -45,6 +55,14 @@
/* End PBXCopyFilesBuildPhase section */

/* Begin PBXFileReference section */
7E1DC50A240E5A4B00D0A061 /* shared.css */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.css; path = shared.css; sourceTree = "<group>"; };
7E1DC51E240E6CE300D0A061 /* Renderer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Renderer.swift; sourceTree = "<group>"; };
7E1DC520240E6D8000D0A061 /* MarkdownRenderer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MarkdownRenderer.swift; sourceTree = "<group>"; };
7E1DC527240E6F4A00D0A061 /* RendererFactory.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = RendererFactory.swift; sourceTree = "<group>"; };
7E1DC529240E6FDE00D0A061 /* CodeRenderer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = CodeRenderer.swift; sourceTree = "<group>"; };
7E35BFBF2410F60F00AB0A3C /* prism.min.css */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.css; path = prism.min.css; sourceTree = "<group>"; };
7E35BFC02410F60F00AB0A3C /* prism.min.js */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.javascript; path = prism.min.js; sourceTree = "<group>"; };
7E35BFC32410FDD800AB0A3C /* minireset.min.css */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.css; name = minireset.min.css; path = QLPlugin/Assets/minireset.min.css; sourceTree = SOURCE_ROOT; };
7E59DDD6240CC3B2009A4E05 /* .gitignore */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = .gitignore; sourceTree = SOURCE_ROOT; };
7E6EF1FA240CC802009E4199 /* QLPlugin.appex */ = {isa = PBXFileReference; explicitFileType = "wrapper.app-extension"; includeInIndex = 0; path = QLPlugin.appex; sourceTree = BUILT_PRODUCTS_DIR; };
7E6EF1FC240CC802009E4199 /* Quartz.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Quartz.framework; path = System/Library/Frameworks/Quartz.framework; sourceTree = SDKROOT; };
Expand All @@ -54,20 +72,22 @@
7E8DEE94240CC47B007A1477 /* .swiftformat */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = .swiftformat; sourceTree = SOURCE_ROOT; };
7E8DEE95240CC47B007A1477 /* .swiftlint.yml */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.yaml; path = .swiftlint.yml; sourceTree = SOURCE_ROOT; };
7E8DEE98240CC4D2007A1477 /* GlanceApp.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GlanceApp.swift; sourceTree = "<group>"; };
7EAC01E9240D2063009505D0 /* PreviewWebView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PreviewWebView.swift; sourceTree = "<group>"; };
7EAC01EB240D220B009505D0 /* FileInfo.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FileInfo.swift; sourceTree = "<group>"; };
7ECC8CEE240CB4CC000D6970 /* Glance.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Glance.app; sourceTree = BUILT_PRODUCTS_DIR; };
7ECC8CF1240CB4CC000D6970 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; };
7ECC8CF3240CB4CC000D6970 /* ViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ViewController.swift; sourceTree = "<group>"; };
7ECC8CF5240CB4CC000D6970 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; };
7ECC8CFA240CB4CC000D6970 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; };
7ECC8CFB240CB4CC000D6970 /* Glance.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = Glance.entitlements; sourceTree = "<group>"; };
7ECE2C68240CF317001711C7 /* content.html */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.html; name = content.html; path = static/content.html; sourceTree = "<group>"; };
/* End PBXFileReference section */

/* Begin PBXFrameworksBuildPhase section */
7E6EF1F7240CC802009E4199 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
7E1DC524240E6DCD00D0A061 /* Down in Frameworks */,
7E6EF1FD240CC802009E4199 /* Quartz.framework in Frameworks */,
);
runOnlyForDeploymentPostprocessing = 0;
Expand All @@ -82,6 +102,50 @@
/* End PBXFrameworksBuildPhase section */

/* Begin PBXGroup section */
7E1DC51C240E674300D0A061 /* Utils */ = {
isa = PBXGroup;
children = (
7EAC01EB240D220B009505D0 /* FileInfo.swift */,
);
path = Utils;
sourceTree = "<group>";
};
7E1DC51D240E68AF00D0A061 /* Views */ = {
isa = PBXGroup;
children = (
7EAC01E9240D2063009505D0 /* PreviewWebView.swift */,
);
path = Views;
sourceTree = "<group>";
};
7E1DC52B240E91FC00D0A061 /* Assets */ = {
isa = PBXGroup;
children = (
7E1DC52D240E9D2C00D0A061 /* code */,
7E35BFC32410FDD800AB0A3C /* minireset.min.css */,
7E1DC50A240E5A4B00D0A061 /* shared.css */,
);
path = Assets;
sourceTree = "<group>";
};
7E1DC52C240E9A3700D0A061 /* Subclasses */ = {
isa = PBXGroup;
children = (
7E1DC529240E6FDE00D0A061 /* CodeRenderer.swift */,
7E1DC520240E6D8000D0A061 /* MarkdownRenderer.swift */,
);
path = Subclasses;
sourceTree = "<group>";
};
7E1DC52D240E9D2C00D0A061 /* code */ = {
isa = PBXGroup;
children = (
7E35BFBF2410F60F00AB0A3C /* prism.min.css */,
7E35BFC02410F60F00AB0A3C /* prism.min.js */,
);
path = code;
sourceTree = "<group>";
};
7E6EF1FB240CC802009E4199 /* Frameworks */ = {
isa = PBXGroup;
children = (
Expand All @@ -93,14 +157,27 @@
7E6EF1FE240CC802009E4199 /* QLPlugin */ = {
isa = PBXGroup;
children = (
7E1DC52B240E91FC00D0A061 /* Assets */,
7E1DC51D240E68AF00D0A061 /* Views */,
7EAC01E1240D1E94009505D0 /* Renderers */,
7E1DC51C240E674300D0A061 /* Utils */,
7E6EF1FF240CC802009E4199 /* PreviewViewController.swift */,
7E6EF204240CC802009E4199 /* Info.plist */,
7E6EF205240CC802009E4199 /* QLPlugin.entitlements */,
7ECE2C68240CF317001711C7 /* content.html */,
);
path = QLPlugin;
sourceTree = "<group>";
};
7EAC01E1240D1E94009505D0 /* Renderers */ = {
isa = PBXGroup;
children = (
7E1DC527240E6F4A00D0A061 /* RendererFactory.swift */,
7E1DC51E240E6CE300D0A061 /* Renderer.swift */,
7E1DC52C240E9A3700D0A061 /* Subclasses */,
);
path = Renderers;
sourceTree = "<group>";
};
7ECC8CE5240CB4CC000D6970 = {
isa = PBXGroup;
children = (
Expand Down Expand Up @@ -152,6 +229,9 @@
dependencies = (
);
name = QLPlugin;
packageProductDependencies = (
7E1DC523240E6DCD00D0A061 /* Down */,
);
productName = QLPlugin;
productReference = 7E6EF1FA240CC802009E4199 /* QLPlugin.appex */;
productType = "com.apple.product-type.app-extension";
Expand Down Expand Up @@ -202,6 +282,9 @@
Base,
);
mainGroup = 7ECC8CE5240CB4CC000D6970;
packageReferences = (
7E1DC522240E6DCD00D0A061 /* XCRemoteSwiftPackageReference "Down" */,
);
productRefGroup = 7ECC8CEF240CB4CC000D6970 /* Products */;
projectDirPath = "";
projectRoot = "";
Expand All @@ -217,7 +300,10 @@
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
7ECE2C69240CF317001711C7 /* content.html in Resources */,
7E35BFC22410F60F00AB0A3C /* prism.min.js in Resources */,
7E35BFC12410F60F00AB0A3C /* prism.min.css in Resources */,
7E1DC515240E5A4B00D0A061 /* shared.css in Resources */,
7E35BFC42410FDD800AB0A3C /* minireset.min.css in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand All @@ -239,7 +325,13 @@
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
7EAC01EC240D220B009505D0 /* FileInfo.swift in Sources */,
7EAC01EA240D2063009505D0 /* PreviewWebView.swift in Sources */,
7E1DC51F240E6CE300D0A061 /* Renderer.swift in Sources */,
7E6EF200240CC802009E4199 /* PreviewViewController.swift in Sources */,
7E1DC528240E6F4A00D0A061 /* RendererFactory.swift in Sources */,
7E1DC521240E6D8000D0A061 /* MarkdownRenderer.swift in Sources */,
7E1DC52A240E6FDE00D0A061 /* CodeRenderer.swift in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
Expand Down Expand Up @@ -490,6 +582,25 @@
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */

/* Begin XCRemoteSwiftPackageReference section */
7E1DC522240E6DCD00D0A061 /* XCRemoteSwiftPackageReference "Down" */ = {
isa = XCRemoteSwiftPackageReference;
repositoryURL = "https://github.com/iwasrobbed/Down";
requirement = {
kind = upToNextMajorVersion;
minimumVersion = 0.9.1;
};
};
/* End XCRemoteSwiftPackageReference section */

/* Begin XCSwiftPackageProductDependency section */
7E1DC523240E6DCD00D0A061 /* Down */ = {
isa = XCSwiftPackageProductDependency;
package = 7E1DC522240E6DCD00D0A061 /* XCRemoteSwiftPackageReference "Down" */;
productName = Down;
};
/* End XCSwiftPackageProductDependency section */
};
rootObject = 7ECC8CE6240CB4CC000D6970 /* Project object */;
}
78 changes: 78 additions & 0 deletions Glance.xcodeproj/xcshareddata/xcschemes/Glance.xcscheme
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1130"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7ECC8CED240CB4CC000D6970"
BuildableName = "Glance.app"
BlueprintName = "Glance"
ReferencedContainer = "container:Glance.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
</Testables>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7ECC8CED240CB4CC000D6970"
BuildableName = "Glance.app"
BlueprintName = "Glance"
ReferencedContainer = "container:Glance.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7ECC8CED240CB4CC000D6970"
BuildableName = "Glance.app"
BlueprintName = "Glance"
ReferencedContainer = "container:Glance.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
Loading

0 comments on commit f24e1c8

Please sign in to comment.