├── .gitattributes ├── .gitignore ├── LICENSE ├── README.md ├── vue-to-mvc5.sln └── vue-to-mvc5 ├── .babelrc ├── .editorconfig ├── .gitignore ├── App_Start └── RouteConfig.cs ├── Areas ├── first │ ├── Controllers │ │ └── HomeController.cs │ ├── Views │ │ ├── Home │ │ │ └── Index.cshtml │ │ ├── Shared │ │ │ └── _Layout.cshtml │ │ ├── _ViewStart.cshtml │ │ └── web.config │ └── firstAreaRegistration.cs └── second │ ├── Controllers │ └── HomeController.cs │ ├── Views │ ├── Home │ │ └── Index.cshtml │ ├── Shared │ │ └── _Layout.cshtml │ ├── _ViewStart.cshtml │ └── web.config │ └── secondAreaRegistration.cs ├── Content ├── Site.css ├── bootstrap.css └── bootstrap.min.css ├── Global.asax ├── Global.asax.cs ├── Properties └── AssemblyInfo.cs ├── README.md ├── Scripts ├── app │ ├── first │ │ ├── App.vue │ │ ├── assets │ │ │ └── logo.png │ │ └── main.js │ └── second │ │ ├── App.vue │ │ ├── assets │ │ └── logo.png │ │ └── main.js ├── bootstrap.js ├── bootstrap.min.js ├── bundle │ ├── first.js │ ├── logo.png │ └── second.js ├── jquery-1.10.2.intellisense.js ├── jquery-1.10.2.js ├── jquery-1.10.2.min.js ├── jquery-1.10.2.min.map └── modernizr-2.6.2.js ├── Views └── web.config ├── Web.Debug.config ├── Web.Release.config ├── Web.config ├── fonts ├── glyphicons-halflings-regular.eot ├── glyphicons-halflings-regular.svg ├── glyphicons-halflings-regular.ttf └── glyphicons-halflings-regular.woff ├── index.html ├── package-lock.json ├── package.json ├── packages.config ├── vue-to-mvc5.csproj └── webpack.config.js /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto 3 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | ## Ignore Visual Studio temporary files, build results, and 2 | ## files generated by popular Visual Studio add-ons. 3 | ## 4 | ## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore 5 | 6 | # User-specific files 7 | *.suo 8 | *.user 9 | *.userosscache 10 | *.sln.docstates 11 | 12 | # User-specific files (MonoDevelop/Xamarin Studio) 13 | *.userprefs 14 | 15 | # Build results 16 | [Dd]ebug/ 17 | [Dd]ebugPublic/ 18 | [Rr]elease/ 19 | [Rr]eleases/ 20 | x64/ 21 | x86/ 22 | bld/ 23 | [Bb]in/ 24 | [Oo]bj/ 25 | [Ll]og/ 26 | 27 | # Visual Studio 2015 cache/options directory 28 | .vs/ 29 | # Uncomment if you have tasks that create the project's static files in wwwroot 30 | #wwwroot/ 31 | 32 | # MSTest test Results 33 | [Tt]est[Rr]esult*/ 34 | [Bb]uild[Ll]og.* 35 | 36 | # NUNIT 37 | *.VisualState.xml 38 | TestResult.xml 39 | 40 | # Build Results of an ATL Project 41 | [Dd]ebugPS/ 42 | [Rr]eleasePS/ 43 | dlldata.c 44 | 45 | # Benchmark Results 46 | BenchmarkDotNet.Artifacts/ 47 | 48 | # .NET Core 49 | project.lock.json 50 | project.fragment.lock.json 51 | artifacts/ 52 | **/Properties/launchSettings.json 53 | 54 | *_i.c 55 | *_p.c 56 | *_i.h 57 | *.ilk 58 | *.meta 59 | *.obj 60 | *.pch 61 | *.pdb 62 | *.pgc 63 | *.pgd 64 | *.rsp 65 | *.sbr 66 | *.tlb 67 | *.tli 68 | *.tlh 69 | *.tmp 70 | *.tmp_proj 71 | *.log 72 | *.vspscc 73 | *.vssscc 74 | .builds 75 | *.pidb 76 | *.svclog 77 | *.scc 78 | 79 | # Chutzpah Test files 80 | _Chutzpah* 81 | 82 | # Visual C++ cache files 83 | ipch/ 84 | *.aps 85 | *.ncb 86 | *.opendb 87 | *.opensdf 88 | *.sdf 89 | *.cachefile 90 | *.VC.db 91 | *.VC.VC.opendb 92 | 93 | # Visual Studio profiler 94 | *.psess 95 | *.vsp 96 | *.vspx 97 | *.sap 98 | 99 | # TFS 2012 Local Workspace 100 | $tf/ 101 | 102 | # Guidance Automation Toolkit 103 | *.gpState 104 | 105 | # ReSharper is a .NET coding add-in 106 | _ReSharper*/ 107 | *.[Rr]e[Ss]harper 108 | *.DotSettings.user 109 | 110 | # JustCode is a .NET coding add-in 111 | .JustCode 112 | 113 | # TeamCity is a build add-in 114 | _TeamCity* 115 | 116 | # DotCover is a Code Coverage Tool 117 | *.dotCover 118 | 119 | # AxoCover is a Code Coverage Tool 120 | .axoCover/* 121 | !.axoCover/settings.json 122 | 123 | # Visual Studio code coverage results 124 | *.coverage 125 | *.coveragexml 126 | 127 | # NCrunch 128 | _NCrunch_* 129 | .*crunch*.local.xml 130 | nCrunchTemp_* 131 | 132 | # MightyMoose 133 | *.mm.* 134 | AutoTest.Net/ 135 | 136 | # Web workbench (sass) 137 | .sass-cache/ 138 | 139 | # Installshield output folder 140 | [Ee]xpress/ 141 | 142 | # DocProject is a documentation generator add-in 143 | DocProject/buildhelp/ 144 | DocProject/Help/*.HxT 145 | DocProject/Help/*.HxC 146 | DocProject/Help/*.hhc 147 | DocProject/Help/*.hhk 148 | DocProject/Help/*.hhp 149 | DocProject/Help/Html2 150 | DocProject/Help/html 151 | 152 | # Click-Once directory 153 | publish/ 154 | 155 | # Publish Web Output 156 | *.[Pp]ublish.xml 157 | *.azurePubxml 158 | # Note: Comment the next line if you want to checkin your web deploy settings, 159 | # but database connection strings (with potential passwords) will be unencrypted 160 | *.pubxml 161 | *.publishproj 162 | 163 | # Microsoft Azure Web App publish settings. Comment the next line if you want to 164 | # checkin your Azure Web App publish settings, but sensitive information contained 165 | # in these scripts will be unencrypted 166 | PublishScripts/ 167 | 168 | # NuGet Packages 169 | *.nupkg 170 | # The packages folder can be ignored because of Package Restore 171 | **/packages/* 172 | # except build/, which is used as an MSBuild target. 173 | !**/packages/build/ 174 | # Uncomment if necessary however generally it will be regenerated when needed 175 | #!**/packages/repositories.config 176 | # NuGet v3's project.json files produces more ignorable files 177 | *.nuget.props 178 | *.nuget.targets 179 | 180 | # Microsoft Azure Build Output 181 | csx/ 182 | *.build.csdef 183 | 184 | # Microsoft Azure Emulator 185 | ecf/ 186 | rcf/ 187 | 188 | # Windows Store app package directories and files 189 | AppPackages/ 190 | BundleArtifacts/ 191 | Package.StoreAssociation.xml 192 | _pkginfo.txt 193 | *.appx 194 | 195 | # Visual Studio cache files 196 | # files ending in .cache can be ignored 197 | *.[Cc]ache 198 | # but keep track of directories ending in .cache 199 | !*.[Cc]ache/ 200 | 201 | # Others 202 | ClientBin/ 203 | ~$* 204 | *~ 205 | *.dbmdl 206 | *.dbproj.schemaview 207 | *.jfm 208 | *.pfx 209 | *.publishsettings 210 | orleans.codegen.cs 211 | 212 | # Since there are multiple workflows, uncomment next line to ignore bower_components 213 | # (https://github.com/github/gitignore/pull/1529#issuecomment-104372622) 214 | #bower_components/ 215 | 216 | # RIA/Silverlight projects 217 | Generated_Code/ 218 | 219 | # Backup & report files from converting an old project file 220 | # to a newer Visual Studio version. Backup files are not needed, 221 | # because we have git ;-) 222 | _UpgradeReport_Files/ 223 | Backup*/ 224 | UpgradeLog*.XML 225 | UpgradeLog*.htm 226 | 227 | # SQL Server files 228 | *.mdf 229 | *.ldf 230 | *.ndf 231 | 232 | # Business Intelligence projects 233 | *.rdl.data 234 | *.bim.layout 235 | *.bim_*.settings 236 | 237 | # Microsoft Fakes 238 | FakesAssemblies/ 239 | 240 | # GhostDoc plugin setting file 241 | *.GhostDoc.xml 242 | 243 | # Node.js Tools for Visual Studio 244 | .ntvs_analysis.dat 245 | node_modules/ 246 | 247 | # Typescript v1 declaration files 248 | typings/ 249 | 250 | # Visual Studio 6 build log 251 | *.plg 252 | 253 | # Visual Studio 6 workspace options file 254 | *.opt 255 | 256 | # Visual Studio 6 auto-generated workspace file (contains which files were open etc.) 257 | *.vbw 258 | 259 | # Visual Studio LightSwitch build output 260 | **/*.HTMLClient/GeneratedArtifacts 261 | **/*.DesktopClient/GeneratedArtifacts 262 | **/*.DesktopClient/ModelManifest.xml 263 | **/*.Server/GeneratedArtifacts 264 | **/*.Server/ModelManifest.xml 265 | _Pvt_Extensions 266 | 267 | # Paket dependency manager 268 | .paket/paket.exe 269 | paket-files/ 270 | 271 | # FAKE - F# Make 272 | .fake/ 273 | 274 | # JetBrains Rider 275 | .idea/ 276 | *.sln.iml 277 | 278 | # CodeRush 279 | .cr/ 280 | 281 | # Python Tools for Visual Studio (PTVS) 282 | __pycache__/ 283 | *.pyc 284 | 285 | # Cake - Uncomment if you are using it 286 | # tools/** 287 | # !tools/packages.config 288 | 289 | # Tabs Studio 290 | *.tss 291 | 292 | # Telerik's JustMock configuration file 293 | *.jmconfig 294 | 295 | # BizTalk build output 296 | *.btp.cs 297 | *.btm.cs 298 | *.odx.cs 299 | *.xsd.cs 300 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 Hyounwoo 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # vue-to-mvc5 2 | 3 | Integrating Vue.js 2.0 to .NET MVC5 Project 4 | 5 | https://medium.com/@hyounoosung/integrating-vue-js-2-0-to-net-mvc5-project-f97eb5a5b3ad 6 | 7 | -------------------------------------------------------------------------------- /vue-to-mvc5.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio 14 4 | VisualStudioVersion = 14.0.25420.1 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "vue-to-mvc5", "vue-to-mvc5\vue-to-mvc5.csproj", "{F6A9A64E-53DC-4B89-B11F-BEE3876A48C7}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|Any CPU = Debug|Any CPU 11 | Release|Any CPU = Release|Any CPU 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {F6A9A64E-53DC-4B89-B11F-BEE3876A48C7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 15 | {F6A9A64E-53DC-4B89-B11F-BEE3876A48C7}.Debug|Any CPU.Build.0 = Debug|Any CPU 16 | {F6A9A64E-53DC-4B89-B11F-BEE3876A48C7}.Release|Any CPU.ActiveCfg = Release|Any CPU 17 | {F6A9A64E-53DC-4B89-B11F-BEE3876A48C7}.Release|Any CPU.Build.0 = Release|Any CPU 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | EndGlobal 23 | -------------------------------------------------------------------------------- /vue-to-mvc5/.babelrc: -------------------------------------------------------------------------------- 1 | { 2 | "presets": [ 3 | ["env", { "modules": false }], 4 | "stage-3" 5 | ] 6 | } 7 | -------------------------------------------------------------------------------- /vue-to-mvc5/.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | charset = utf-8 5 | indent_style = space 6 | indent_size = 2 7 | end_of_line = lf 8 | insert_final_newline = true 9 | trim_trailing_whitespace = true 10 | -------------------------------------------------------------------------------- /vue-to-mvc5/.gitignore: -------------------------------------------------------------------------------- 1 | .DS_Store 2 | node_modules/ 3 | dist/ 4 | npm-debug.log 5 | yarn-error.log 6 | 7 | # Editor directories and files 8 | .idea 9 | *.suo 10 | *.ntvs* 11 | *.njsproj 12 | *.sln 13 | -------------------------------------------------------------------------------- /vue-to-mvc5/App_Start/RouteConfig.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Mvc; 6 | using System.Web.Routing; 7 | 8 | namespace vue_to_mvc5 9 | { 10 | public class RouteConfig 11 | { 12 | public static void RegisterRoutes(RouteCollection routes) 13 | { 14 | routes.IgnoreRoute("{resource}.axd/{*pathInfo}"); 15 | 16 | routes.MapRoute( 17 | name: "Default", 18 | url: "{controller}/{action}/{id}", 19 | defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional } 20 | ); 21 | } 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/first/Controllers/HomeController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Mvc; 6 | 7 | namespace vue_to_mvc5.Areas.first.Controllers 8 | { 9 | public class HomeController : Controller 10 | { 11 | // GET: first/Default 12 | public ActionResult Index() 13 | { 14 | return View(); 15 | } 16 | 17 | // GET: first/Default/Details/5 18 | public ActionResult Details(int id) 19 | { 20 | return View(); 21 | } 22 | 23 | // GET: first/Default/Create 24 | public ActionResult Create() 25 | { 26 | return View(); 27 | } 28 | 29 | // POST: first/Default/Create 30 | [HttpPost] 31 | public ActionResult Create(FormCollection collection) 32 | { 33 | try 34 | { 35 | // TODO: Add insert logic here 36 | 37 | return RedirectToAction("Index"); 38 | } 39 | catch 40 | { 41 | return View(); 42 | } 43 | } 44 | 45 | // GET: first/Default/Edit/5 46 | public ActionResult Edit(int id) 47 | { 48 | return View(); 49 | } 50 | 51 | // POST: first/Default/Edit/5 52 | [HttpPost] 53 | public ActionResult Edit(int id, FormCollection collection) 54 | { 55 | try 56 | { 57 | // TODO: Add update logic here 58 | 59 | return RedirectToAction("Index"); 60 | } 61 | catch 62 | { 63 | return View(); 64 | } 65 | } 66 | 67 | // GET: first/Default/Delete/5 68 | public ActionResult Delete(int id) 69 | { 70 | return View(); 71 | } 72 | 73 | // POST: first/Default/Delete/5 74 | [HttpPost] 75 | public ActionResult Delete(int id, FormCollection collection) 76 | { 77 | try 78 | { 79 | // TODO: Add delete logic here 80 | 81 | return RedirectToAction("Index"); 82 | } 83 | catch 84 | { 85 | return View(); 86 | } 87 | } 88 | } 89 | } 90 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/first/Views/Home/Index.cshtml: -------------------------------------------------------------------------------- 1 | 
2 | 3 |
4 | 5 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/first/Views/Shared/_Layout.cshtml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | @ViewData["Title"] - WebApplication 7 | 8 | 9 | @RenderBody() 10 | 11 | @RenderSection("scripts", required: false) 12 | 13 | 14 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/first/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "~/Areas/first/Views/Shared/_Layout.cshtml"; 3 | } -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/first/Views/web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 |
7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/first/firstAreaRegistration.cs: -------------------------------------------------------------------------------- 1 | using System.Web.Mvc; 2 | 3 | namespace vue_to_mvc5.Areas.first 4 | { 5 | public class firstAreaRegistration : AreaRegistration 6 | { 7 | public override string AreaName 8 | { 9 | get 10 | { 11 | return "first"; 12 | } 13 | } 14 | 15 | public override void RegisterArea(AreaRegistrationContext context) 16 | { 17 | context.MapRoute( 18 | "first_default", 19 | "first/{controller}/{action}/{id}", 20 | new { action = "Index", id = UrlParameter.Optional } 21 | ); 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/second/Controllers/HomeController.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Mvc; 6 | 7 | namespace vue_to_mvc5.Areas.second.Controllers 8 | { 9 | public class HomeController : Controller 10 | { 11 | // GET: second/Second 12 | public ActionResult Index() 13 | { 14 | return View(); 15 | } 16 | 17 | // GET: second/Second/Details/5 18 | public ActionResult Details(int id) 19 | { 20 | return View(); 21 | } 22 | 23 | // GET: second/Second/Create 24 | public ActionResult Create() 25 | { 26 | return View(); 27 | } 28 | 29 | // POST: second/Second/Create 30 | [HttpPost] 31 | public ActionResult Create(FormCollection collection) 32 | { 33 | try 34 | { 35 | // TODO: Add insert logic here 36 | 37 | return RedirectToAction("Index"); 38 | } 39 | catch 40 | { 41 | return View(); 42 | } 43 | } 44 | 45 | // GET: second/Second/Edit/5 46 | public ActionResult Edit(int id) 47 | { 48 | return View(); 49 | } 50 | 51 | // POST: second/Second/Edit/5 52 | [HttpPost] 53 | public ActionResult Edit(int id, FormCollection collection) 54 | { 55 | try 56 | { 57 | // TODO: Add update logic here 58 | 59 | return RedirectToAction("Index"); 60 | } 61 | catch 62 | { 63 | return View(); 64 | } 65 | } 66 | 67 | // GET: second/Second/Delete/5 68 | public ActionResult Delete(int id) 69 | { 70 | return View(); 71 | } 72 | 73 | // POST: second/Second/Delete/5 74 | [HttpPost] 75 | public ActionResult Delete(int id, FormCollection collection) 76 | { 77 | try 78 | { 79 | // TODO: Add delete logic here 80 | 81 | return RedirectToAction("Index"); 82 | } 83 | catch 84 | { 85 | return View(); 86 | } 87 | } 88 | } 89 | } 90 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/second/Views/Home/Index.cshtml: -------------------------------------------------------------------------------- 1 | 
2 | 3 |
4 | 5 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/second/Views/Shared/_Layout.cshtml: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | @ViewData["Title"] - WebApplication 7 | 8 | 9 | @RenderBody() 10 | 11 | @RenderSection("scripts", required: false) 12 | 13 | 14 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/second/Views/_ViewStart.cshtml: -------------------------------------------------------------------------------- 1 | @{ 2 | Layout = "~/Areas/second/Views/Shared/_Layout.cshtml"; 3 | } -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/second/Views/web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 |
7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /vue-to-mvc5/Areas/second/secondAreaRegistration.cs: -------------------------------------------------------------------------------- 1 | using System.Web.Mvc; 2 | 3 | namespace vue_to_mvc5.Areas.second 4 | { 5 | public class secondAreaRegistration : AreaRegistration 6 | { 7 | public override string AreaName 8 | { 9 | get 10 | { 11 | return "second"; 12 | } 13 | } 14 | 15 | public override void RegisterArea(AreaRegistrationContext context) 16 | { 17 | context.MapRoute( 18 | "second_default", 19 | "second/{controller}/{action}/{id}", 20 | new { action = "Index", id = UrlParameter.Optional } 21 | ); 22 | } 23 | } 24 | } -------------------------------------------------------------------------------- /vue-to-mvc5/Content/Site.css: -------------------------------------------------------------------------------- 1 | body { 2 | padding-top: 50px; 3 | padding-bottom: 20px; 4 | } 5 | 6 | /* Set padding to keep content from hitting the edges */ 7 | .body-content { 8 | padding-left: 15px; 9 | padding-right: 15px; 10 | } 11 | 12 | /* Set width on the form input elements since they're 100% wide by default */ 13 | input, 14 | select, 15 | textarea { 16 | max-width: 280px; 17 | } 18 | 19 | -------------------------------------------------------------------------------- /vue-to-mvc5/Global.asax: -------------------------------------------------------------------------------- 1 | <%@ Application Codebehind="Global.asax.cs" Inherits="vue_to_mvc5.MvcApplication" Language="C#" %> 2 | -------------------------------------------------------------------------------- /vue-to-mvc5/Global.asax.cs: -------------------------------------------------------------------------------- 1 | using System; 2 | using System.Collections.Generic; 3 | using System.Linq; 4 | using System.Web; 5 | using System.Web.Mvc; 6 | using System.Web.Routing; 7 | 8 | namespace vue_to_mvc5 9 | { 10 | public class MvcApplication : System.Web.HttpApplication 11 | { 12 | protected void Application_Start() 13 | { 14 | AreaRegistration.RegisterAllAreas(); 15 | RouteConfig.RegisterRoutes(RouteTable.Routes); 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /vue-to-mvc5/Properties/AssemblyInfo.cs: -------------------------------------------------------------------------------- 1 | using System.Reflection; 2 | using System.Runtime.CompilerServices; 3 | using System.Runtime.InteropServices; 4 | 5 | // General Information about an assembly is controlled through the following 6 | // set of attributes. Change these attribute values to modify the information 7 | // associated with an assembly. 8 | [assembly: AssemblyTitle("vue_to_mvc5")] 9 | [assembly: AssemblyDescription("")] 10 | [assembly: AssemblyConfiguration("")] 11 | [assembly: AssemblyCompany("Microsoft")] 12 | [assembly: AssemblyProduct("vue_to_mvc5")] 13 | [assembly: AssemblyCopyright("Copyright © Microsoft 2018")] 14 | [assembly: AssemblyTrademark("")] 15 | [assembly: AssemblyCulture("")] 16 | 17 | // Setting ComVisible to false makes the types in this assembly not visible 18 | // to COM components. If you need to access a type in this assembly from 19 | // COM, set the ComVisible attribute to true on that type. 20 | [assembly: ComVisible(false)] 21 | 22 | // The following GUID is for the ID of the typelib if this project is exposed to COM 23 | [assembly: Guid("f6a9a64e-53dc-4b89-b11f-bee3876a48c7")] 24 | 25 | // Version information for an assembly consists of the following four values: 26 | // 27 | // Major Version 28 | // Minor Version 29 | // Build Number 30 | // Revision 31 | // 32 | // You can specify all the values or you can default the Revision and Build Numbers 33 | // by using the '*' as shown below: 34 | [assembly: AssemblyVersion("1.0.0.0")] 35 | [assembly: AssemblyFileVersion("1.0.0.0")] 36 | -------------------------------------------------------------------------------- /vue-to-mvc5/README.md: -------------------------------------------------------------------------------- 1 | # vue-to-mvc5 2 | 3 | > A Vue.js project 4 | 5 | ## Build Setup 6 | 7 | ``` bash 8 | # install dependencies 9 | npm install 10 | 11 | # serve with hot reload at localhost:8080 12 | npm run dev 13 | 14 | # build for production with minification 15 | npm run build 16 | ``` 17 | 18 | For detailed explanation on how things work, consult the [docs for vue-loader](http://vuejs.github.io/vue-loader). 19 | -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/app/first/App.vue: -------------------------------------------------------------------------------- 1 | 21 | 22 | 32 | 33 | 61 | -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/app/first/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hyunoosung/vue-to-mvc5/f025d5f091efe851d43a77f49141a4a3f966dea5/vue-to-mvc5/Scripts/app/first/assets/logo.png -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/app/first/main.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import App from './App.vue' 3 | import Vuetify from 'vuetify' 4 | 5 | Vue.use(Vuetify) 6 | new Vue({ 7 | el: '#app', 8 | render: h => h(App) 9 | }) 10 | -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/app/second/App.vue: -------------------------------------------------------------------------------- 1 | 21 | 22 | 32 | 33 | 61 | -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/app/second/assets/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hyunoosung/vue-to-mvc5/f025d5f091efe851d43a77f49141a4a3f966dea5/vue-to-mvc5/Scripts/app/second/assets/logo.png -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/app/second/main.js: -------------------------------------------------------------------------------- 1 | import Vue from 'vue' 2 | import App from './App.vue' 3 | 4 | new Vue({ 5 | el: '#app', 6 | render: h => h(App) 7 | }) 8 | -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/bootstrap.min.js: -------------------------------------------------------------------------------- 1 | /* NUGET: BEGIN LICENSE TEXT 2 | * 3 | * Microsoft grants you the right to use these script files for the sole 4 | * purpose of either: (i) interacting through your browser with the Microsoft 5 | * website or online service, subject to the applicable licensing or use 6 | * terms; or (ii) using the files as included with a Microsoft product subject 7 | * to that product's license terms. Microsoft reserves all other rights to the 8 | * files not expressly granted by Microsoft, whether by implication, estoppel 9 | * or otherwise. Insofar as a script file is dual licensed under GPL, 10 | * Microsoft neither took the code under GPL nor distributes it thereunder but 11 | * under the terms set out in this paragraph. All notices and licenses 12 | * below are for informational purposes only. 13 | * 14 | * NUGET: END LICENSE TEXT */ 15 | 16 | /** 17 | * bootstrap.js v3.0.0 by @fat and @mdo 18 | * Copyright 2013 Twitter Inc. 19 | * http://www.apache.org/licenses/LICENSE-2.0 20 | */ 21 | if(!jQuery)throw new Error("Bootstrap requires jQuery");+function(a){"use strict";function b(){var a=document.createElement("bootstrap"),b={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var c in b)if(void 0!==a.style[c])return{end:b[c]}}a.fn.emulateTransitionEnd=function(b){var c=!1,d=this;a(this).one(a.support.transition.end,function(){c=!0});var e=function(){c||a(d).trigger(a.support.transition.end)};return setTimeout(e,b),this},a(function(){a.support.transition=b()})}(window.jQuery),+function(a){"use strict";var b='[data-dismiss="alert"]',c=function(c){a(c).on("click",b,this.close)};c.prototype.close=function(b){function c(){f.trigger("closed.bs.alert").remove()}var d=a(this),e=d.attr("data-target");e||(e=d.attr("href"),e=e&&e.replace(/.*(?=#[^\s]*$)/,""));var f=a(e);b&&b.preventDefault(),f.length||(f=d.hasClass("alert")?d:d.parent()),f.trigger(b=a.Event("close.bs.alert")),b.isDefaultPrevented()||(f.removeClass("in"),a.support.transition&&f.hasClass("fade")?f.one(a.support.transition.end,c).emulateTransitionEnd(150):c())};var d=a.fn.alert;a.fn.alert=function(b){return this.each(function(){var d=a(this),e=d.data("bs.alert");e||d.data("bs.alert",e=new c(this)),"string"==typeof b&&e[b].call(d)})},a.fn.alert.Constructor=c,a.fn.alert.noConflict=function(){return a.fn.alert=d,this},a(document).on("click.bs.alert.data-api",b,c.prototype.close)}(window.jQuery),+function(a){"use strict";var b=function(c,d){this.$element=a(c),this.options=a.extend({},b.DEFAULTS,d)};b.DEFAULTS={loadingText:"loading..."},b.prototype.setState=function(a){var b="disabled",c=this.$element,d=c.is("input")?"val":"html",e=c.data();a+="Text",e.resetText||c.data("resetText",c[d]()),c[d](e[a]||this.options[a]),setTimeout(function(){"loadingText"==a?c.addClass(b).attr(b,b):c.removeClass(b).removeAttr(b)},0)},b.prototype.toggle=function(){var a=this.$element.closest('[data-toggle="buttons"]');if(a.length){var b=this.$element.find("input").prop("checked",!this.$element.hasClass("active")).trigger("change");"radio"===b.prop("type")&&a.find(".active").removeClass("active")}this.$element.toggleClass("active")};var c=a.fn.button;a.fn.button=function(c){return this.each(function(){var d=a(this),e=d.data("bs.button"),f="object"==typeof c&&c;e||d.data("bs.button",e=new b(this,f)),"toggle"==c?e.toggle():c&&e.setState(c)})},a.fn.button.Constructor=b,a.fn.button.noConflict=function(){return a.fn.button=c,this},a(document).on("click.bs.button.data-api","[data-toggle^=button]",function(b){var c=a(b.target);c.hasClass("btn")||(c=c.closest(".btn")),c.button("toggle"),b.preventDefault()})}(window.jQuery),+function(a){"use strict";var b=function(b,c){this.$element=a(b),this.$indicators=this.$element.find(".carousel-indicators"),this.options=c,this.paused=this.sliding=this.interval=this.$active=this.$items=null,"hover"==this.options.pause&&this.$element.on("mouseenter",a.proxy(this.pause,this)).on("mouseleave",a.proxy(this.cycle,this))};b.DEFAULTS={interval:5e3,pause:"hover",wrap:!0},b.prototype.cycle=function(b){return b||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(a.proxy(this.next,this),this.options.interval)),this},b.prototype.getActiveIndex=function(){return this.$active=this.$element.find(".item.active"),this.$items=this.$active.parent().children(),this.$items.index(this.$active)},b.prototype.to=function(b){var c=this,d=this.getActiveIndex();return b>this.$items.length-1||0>b?void 0:this.sliding?this.$element.one("slid",function(){c.to(b)}):d==b?this.pause().cycle():this.slide(b>d?"next":"prev",a(this.$items[b]))},b.prototype.pause=function(b){return b||(this.paused=!0),this.$element.find(".next, .prev").length&&a.support.transition.end&&(this.$element.trigger(a.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},b.prototype.next=function(){return this.sliding?void 0:this.slide("next")},b.prototype.prev=function(){return this.sliding?void 0:this.slide("prev")},b.prototype.slide=function(b,c){var d=this.$element.find(".item.active"),e=c||d[b](),f=this.interval,g="next"==b?"left":"right",h="next"==b?"first":"last",i=this;if(!e.length){if(!this.options.wrap)return;e=this.$element.find(".item")[h]()}this.sliding=!0,f&&this.pause();var j=a.Event("slide.bs.carousel",{relatedTarget:e[0],direction:g});if(!e.hasClass("active")){if(this.$indicators.length&&(this.$indicators.find(".active").removeClass("active"),this.$element.one("slid",function(){var b=a(i.$indicators.children()[i.getActiveIndex()]);b&&b.addClass("active")})),a.support.transition&&this.$element.hasClass("slide")){if(this.$element.trigger(j),j.isDefaultPrevented())return;e.addClass(b),e[0].offsetWidth,d.addClass(g),e.addClass(g),d.one(a.support.transition.end,function(){e.removeClass([b,g].join(" ")).addClass("active"),d.removeClass(["active",g].join(" ")),i.sliding=!1,setTimeout(function(){i.$element.trigger("slid")},0)}).emulateTransitionEnd(600)}else{if(this.$element.trigger(j),j.isDefaultPrevented())return;d.removeClass("active"),e.addClass("active"),this.sliding=!1,this.$element.trigger("slid")}return f&&this.cycle(),this}};var c=a.fn.carousel;a.fn.carousel=function(c){return this.each(function(){var d=a(this),e=d.data("bs.carousel"),f=a.extend({},b.DEFAULTS,d.data(),"object"==typeof c&&c),g="string"==typeof c?c:f.slide;e||d.data("bs.carousel",e=new b(this,f)),"number"==typeof c?e.to(c):g?e[g]():f.interval&&e.pause().cycle()})},a.fn.carousel.Constructor=b,a.fn.carousel.noConflict=function(){return a.fn.carousel=c,this},a(document).on("click.bs.carousel.data-api","[data-slide], [data-slide-to]",function(b){var c,d=a(this),e=a(d.attr("data-target")||(c=d.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,"")),f=a.extend({},e.data(),d.data()),g=d.attr("data-slide-to");g&&(f.interval=!1),e.carousel(f),(g=d.attr("data-slide-to"))&&e.data("bs.carousel").to(g),b.preventDefault()}),a(window).on("load",function(){a('[data-ride="carousel"]').each(function(){var b=a(this);b.carousel(b.data())})})}(window.jQuery),+function(a){"use strict";var b=function(c,d){this.$element=a(c),this.options=a.extend({},b.DEFAULTS,d),this.transitioning=null,this.options.parent&&(this.$parent=a(this.options.parent)),this.options.toggle&&this.toggle()};b.DEFAULTS={toggle:!0},b.prototype.dimension=function(){var a=this.$element.hasClass("width");return a?"width":"height"},b.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var b=a.Event("show.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.$parent&&this.$parent.find("> .panel > .in");if(c&&c.length){var d=c.data("bs.collapse");if(d&&d.transitioning)return;c.collapse("hide"),d||c.data("bs.collapse",null)}var e=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[e](0),this.transitioning=1;var f=function(){this.$element.removeClass("collapsing").addClass("in")[e]("auto"),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return f.call(this);var g=a.camelCase(["scroll",e].join("-"));this.$element.one(a.support.transition.end,a.proxy(f,this)).emulateTransitionEnd(350)[e](this.$element[0][g])}}},b.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var b=a.Event("hide.bs.collapse");if(this.$element.trigger(b),!b.isDefaultPrevented()){var c=this.dimension();this.$element[c](this.$element[c]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse").removeClass("in"),this.transitioning=1;var d=function(){this.transitioning=0,this.$element.trigger("hidden.bs.collapse").removeClass("collapsing").addClass("collapse")};return a.support.transition?(this.$element[c](0).one(a.support.transition.end,a.proxy(d,this)).emulateTransitionEnd(350),void 0):d.call(this)}}},b.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()};var c=a.fn.collapse;a.fn.collapse=function(c){return this.each(function(){var d=a(this),e=d.data("bs.collapse"),f=a.extend({},b.DEFAULTS,d.data(),"object"==typeof c&&c);e||d.data("bs.collapse",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.collapse.Constructor=b,a.fn.collapse.noConflict=function(){return a.fn.collapse=c,this},a(document).on("click.bs.collapse.data-api","[data-toggle=collapse]",function(b){var c,d=a(this),e=d.attr("data-target")||b.preventDefault()||(c=d.attr("href"))&&c.replace(/.*(?=#[^\s]+$)/,""),f=a(e),g=f.data("bs.collapse"),h=g?"toggle":d.data(),i=d.attr("data-parent"),j=i&&a(i);g&&g.transitioning||(j&&j.find('[data-toggle=collapse][data-parent="'+i+'"]').not(d).addClass("collapsed"),d[f.hasClass("in")?"addClass":"removeClass"]("collapsed")),f.collapse(h)})}(window.jQuery),+function(a){"use strict";function b(){a(d).remove(),a(e).each(function(b){var d=c(a(this));d.hasClass("open")&&(d.trigger(b=a.Event("hide.bs.dropdown")),b.isDefaultPrevented()||d.removeClass("open").trigger("hidden.bs.dropdown"))})}function c(b){var c=b.attr("data-target");c||(c=b.attr("href"),c=c&&/#/.test(c)&&c.replace(/.*(?=#[^\s]*$)/,""));var d=c&&a(c);return d&&d.length?d:b.parent()}var d=".dropdown-backdrop",e="[data-toggle=dropdown]",f=function(b){a(b).on("click.bs.dropdown",this.toggle)};f.prototype.toggle=function(d){var e=a(this);if(!e.is(".disabled, :disabled")){var f=c(e),g=f.hasClass("open");if(b(),!g){if("ontouchstart"in document.documentElement&&!f.closest(".navbar-nav").length&&a(''}),b.prototype=a.extend({},a.fn.tooltip.Constructor.prototype),b.prototype.constructor=b,b.prototype.getDefaults=function(){return b.DEFAULTS},b.prototype.setContent=function(){var a=this.tip(),b=this.getTitle(),c=this.getContent();a.find(".popover-title")[this.options.html?"html":"text"](b),a.find(".popover-content")[this.options.html?"html":"text"](c),a.removeClass("fade top bottom left right in"),a.find(".popover-title").html()||a.find(".popover-title").hide()},b.prototype.hasContent=function(){return this.getTitle()||this.getContent()},b.prototype.getContent=function(){var a=this.$element,b=this.options;return a.attr("data-content")||("function"==typeof b.content?b.content.call(a[0]):b.content)},b.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")},b.prototype.tip=function(){return this.$tip||(this.$tip=a(this.options.template)),this.$tip};var c=a.fn.popover;a.fn.popover=function(c){return this.each(function(){var d=a(this),e=d.data("bs.popover"),f="object"==typeof c&&c;e||d.data("bs.popover",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.popover.Constructor=b,a.fn.popover.noConflict=function(){return a.fn.popover=c,this}}(window.jQuery),+function(a){"use strict";function b(c,d){var e,f=a.proxy(this.process,this);this.$element=a(c).is("body")?a(window):a(c),this.$body=a("body"),this.$scrollElement=this.$element.on("scroll.bs.scroll-spy.data-api",f),this.options=a.extend({},b.DEFAULTS,d),this.selector=(this.options.target||(e=a(c).attr("href"))&&e.replace(/.*(?=#[^\s]+$)/,"")||"")+" .nav li > a",this.offsets=a([]),this.targets=a([]),this.activeTarget=null,this.refresh(),this.process()}b.DEFAULTS={offset:10},b.prototype.refresh=function(){var b=this.$element[0]==window?"offset":"position";this.offsets=a([]),this.targets=a([]);var c=this;this.$body.find(this.selector).map(function(){var d=a(this),e=d.data("target")||d.attr("href"),f=/^#\w/.test(e)&&a(e);return f&&f.length&&[[f[b]().top+(!a.isWindow(c.$scrollElement.get(0))&&c.$scrollElement.scrollTop()),e]]||null}).sort(function(a,b){return a[0]-b[0]}).each(function(){c.offsets.push(this[0]),c.targets.push(this[1])})},b.prototype.process=function(){var a,b=this.$scrollElement.scrollTop()+this.options.offset,c=this.$scrollElement[0].scrollHeight||this.$body[0].scrollHeight,d=c-this.$scrollElement.height(),e=this.offsets,f=this.targets,g=this.activeTarget;if(b>=d)return g!=(a=f.last()[0])&&this.activate(a);for(a=e.length;a--;)g!=f[a]&&b>=e[a]&&(!e[a+1]||b<=e[a+1])&&this.activate(f[a])},b.prototype.activate=function(b){this.activeTarget=b,a(this.selector).parents(".active").removeClass("active");var c=this.selector+'[data-target="'+b+'"],'+this.selector+'[href="'+b+'"]',d=a(c).parents("li").addClass("active");d.parent(".dropdown-menu").length&&(d=d.closest("li.dropdown").addClass("active")),d.trigger("activate")};var c=a.fn.scrollspy;a.fn.scrollspy=function(c){return this.each(function(){var d=a(this),e=d.data("bs.scrollspy"),f="object"==typeof c&&c;e||d.data("bs.scrollspy",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.scrollspy.Constructor=b,a.fn.scrollspy.noConflict=function(){return a.fn.scrollspy=c,this},a(window).on("load",function(){a('[data-spy="scroll"]').each(function(){var b=a(this);b.scrollspy(b.data())})})}(window.jQuery),+function(a){"use strict";var b=function(b){this.element=a(b)};b.prototype.show=function(){var b=this.element,c=b.closest("ul:not(.dropdown-menu)"),d=b.attr("data-target");if(d||(d=b.attr("href"),d=d&&d.replace(/.*(?=#[^\s]*$)/,"")),!b.parent("li").hasClass("active")){var e=c.find(".active:last a")[0],f=a.Event("show.bs.tab",{relatedTarget:e});if(b.trigger(f),!f.isDefaultPrevented()){var g=a(d);this.activate(b.parent("li"),c),this.activate(g,g.parent(),function(){b.trigger({type:"shown.bs.tab",relatedTarget:e})})}}},b.prototype.activate=function(b,c,d){function e(){f.removeClass("active").find("> .dropdown-menu > .active").removeClass("active"),b.addClass("active"),g?(b[0].offsetWidth,b.addClass("in")):b.removeClass("fade"),b.parent(".dropdown-menu")&&b.closest("li.dropdown").addClass("active"),d&&d()}var f=c.find("> .active"),g=d&&a.support.transition&&f.hasClass("fade");g?f.one(a.support.transition.end,e).emulateTransitionEnd(150):e(),f.removeClass("in")};var c=a.fn.tab;a.fn.tab=function(c){return this.each(function(){var d=a(this),e=d.data("bs.tab");e||d.data("bs.tab",e=new b(this)),"string"==typeof c&&e[c]()})},a.fn.tab.Constructor=b,a.fn.tab.noConflict=function(){return a.fn.tab=c,this},a(document).on("click.bs.tab.data-api",'[data-toggle="tab"], [data-toggle="pill"]',function(b){b.preventDefault(),a(this).tab("show")})}(window.jQuery),+function(a){"use strict";var b=function(c,d){this.options=a.extend({},b.DEFAULTS,d),this.$window=a(window).on("scroll.bs.affix.data-api",a.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",a.proxy(this.checkPositionWithEventLoop,this)),this.$element=a(c),this.affixed=this.unpin=null,this.checkPosition()};b.RESET="affix affix-top affix-bottom",b.DEFAULTS={offset:0},b.prototype.checkPositionWithEventLoop=function(){setTimeout(a.proxy(this.checkPosition,this),1)},b.prototype.checkPosition=function(){if(this.$element.is(":visible")){var c=a(document).height(),d=this.$window.scrollTop(),e=this.$element.offset(),f=this.options.offset,g=f.top,h=f.bottom;"object"!=typeof f&&(h=g=f),"function"==typeof g&&(g=f.top()),"function"==typeof h&&(h=f.bottom());var i=null!=this.unpin&&d+this.unpin<=e.top?!1:null!=h&&e.top+this.$element.height()>=c-h?"bottom":null!=g&&g>=d?"top":!1;this.affixed!==i&&(this.unpin&&this.$element.css("top",""),this.affixed=i,this.unpin="bottom"==i?e.top-d:null,this.$element.removeClass(b.RESET).addClass("affix"+(i?"-"+i:"")),"bottom"==i&&this.$element.offset({top:document.body.offsetHeight-h-this.$element.height()}))}};var c=a.fn.affix;a.fn.affix=function(c){return this.each(function(){var d=a(this),e=d.data("bs.affix"),f="object"==typeof c&&c;e||d.data("bs.affix",e=new b(this,f)),"string"==typeof c&&e[c]()})},a.fn.affix.Constructor=b,a.fn.affix.noConflict=function(){return a.fn.affix=c,this},a(window).on("load",function(){a('[data-spy="affix"]').each(function(){var b=a(this),c=b.data();c.offset=c.offset||{},c.offsetBottom&&(c.offset.bottom=c.offsetBottom),c.offsetTop&&(c.offset.top=c.offsetTop),b.affix(c)})})}(window.jQuery); -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/bundle/logo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hyunoosung/vue-to-mvc5/f025d5f091efe851d43a77f49141a4a3f966dea5/vue-to-mvc5/Scripts/bundle/logo.png -------------------------------------------------------------------------------- /vue-to-mvc5/Scripts/modernizr-2.6.2.js: -------------------------------------------------------------------------------- 1 | /* NUGET: BEGIN LICENSE TEXT 2 | * 3 | * Microsoft grants you the right to use these script files for the sole 4 | * purpose of either: (i) interacting through your browser with the Microsoft 5 | * website or online service, subject to the applicable licensing or use 6 | * terms; or (ii) using the files as included with a Microsoft product subject 7 | * to that product's license terms. Microsoft reserves all other rights to the 8 | * files not expressly granted by Microsoft, whether by implication, estoppel 9 | * or otherwise. Insofar as a script file is dual licensed under GPL, 10 | * Microsoft neither took the code under GPL nor distributes it thereunder but 11 | * under the terms set out in this paragraph. All notices and licenses 12 | * below are for informational purposes only. 13 | * 14 | * Copyright (c) Faruk Ates, Paul Irish, Alex Sexton; http://www.modernizr.com/license/ 15 | * 16 | * Includes matchMedia polyfill; Copyright (c) 2010 Filament Group, Inc; http://opensource.org/licenses/MIT 17 | * 18 | * Includes material adapted from ES5-shim https://github.com/kriskowal/es5-shim/blob/master/es5-shim.js; Copyright 2009-2012 by contributors; http://opensource.org/licenses/MIT 19 | * 20 | * Includes material from css-support; Copyright (c) 2005-2012 Diego Perini; https://github.com/dperini/css-support/blob/master/LICENSE 21 | * 22 | * NUGET: END LICENSE TEXT */ 23 | 24 | /*! 25 | * Modernizr v2.6.2 26 | * www.modernizr.com 27 | * 28 | * Copyright (c) Faruk Ates, Paul Irish, Alex Sexton 29 | * Available under the BSD and MIT licenses: www.modernizr.com/license/ 30 | */ 31 | 32 | /* 33 | * Modernizr tests which native CSS3 and HTML5 features are available in 34 | * the current UA and makes the results available to you in two ways: 35 | * as properties on a global Modernizr object, and as classes on the 36 | * element. This information allows you to progressively enhance 37 | * your pages with a granular level of control over the experience. 38 | * 39 | * Modernizr has an optional (not included) conditional resource loader 40 | * called Modernizr.load(), based on Yepnope.js (yepnopejs.com). 41 | * To get a build that includes Modernizr.load(), as well as choosing 42 | * which tests to include, go to www.modernizr.com/download/ 43 | * 44 | * Authors Faruk Ates, Paul Irish, Alex Sexton 45 | * Contributors Ryan Seddon, Ben Alman 46 | */ 47 | 48 | window.Modernizr = (function( window, document, undefined ) { 49 | 50 | var version = '2.6.2', 51 | 52 | Modernizr = {}, 53 | 54 | /*>>cssclasses*/ 55 | // option for enabling the HTML classes to be added 56 | enableClasses = true, 57 | /*>>cssclasses*/ 58 | 59 | docElement = document.documentElement, 60 | 61 | /** 62 | * Create our "modernizr" element that we do most feature tests on. 63 | */ 64 | mod = 'modernizr', 65 | modElem = document.createElement(mod), 66 | mStyle = modElem.style, 67 | 68 | /** 69 | * Create the input element for various Web Forms feature tests. 70 | */ 71 | inputElem /*>>inputelem*/ = document.createElement('input') /*>>inputelem*/ , 72 | 73 | /*>>smile*/ 74 | smile = ':)', 75 | /*>>smile*/ 76 | 77 | toString = {}.toString, 78 | 79 | // TODO :: make the prefixes more granular 80 | /*>>prefixes*/ 81 | // List of property values to set for css tests. See ticket #21 82 | prefixes = ' -webkit- -moz- -o- -ms- '.split(' '), 83 | /*>>prefixes*/ 84 | 85 | /*>>domprefixes*/ 86 | // Following spec is to expose vendor-specific style properties as: 87 | // elem.style.WebkitBorderRadius 88 | // and the following would be incorrect: 89 | // elem.style.webkitBorderRadius 90 | 91 | // Webkit ghosts their properties in lowercase but Opera & Moz do not. 92 | // Microsoft uses a lowercase `ms` instead of the correct `Ms` in IE8+ 93 | // erik.eae.net/archives/2008/03/10/21.48.10/ 94 | 95 | // More here: github.com/Modernizr/Modernizr/issues/issue/21 96 | omPrefixes = 'Webkit Moz O ms', 97 | 98 | cssomPrefixes = omPrefixes.split(' '), 99 | 100 | domPrefixes = omPrefixes.toLowerCase().split(' '), 101 | /*>>domprefixes*/ 102 | 103 | /*>>ns*/ 104 | ns = {'svg': 'http://www.w3.org/2000/svg'}, 105 | /*>>ns*/ 106 | 107 | tests = {}, 108 | inputs = {}, 109 | attrs = {}, 110 | 111 | classes = [], 112 | 113 | slice = classes.slice, 114 | 115 | featureName, // used in testing loop 116 | 117 | 118 | /*>>teststyles*/ 119 | // Inject element with style element and some CSS rules 120 | injectElementWithStyles = function( rule, callback, nodes, testnames ) { 121 | 122 | var style, ret, node, docOverflow, 123 | div = document.createElement('div'), 124 | // After page load injecting a fake body doesn't work so check if body exists 125 | body = document.body, 126 | // IE6 and 7 won't return offsetWidth or offsetHeight unless it's in the body element, so we fake it. 127 | fakeBody = body || document.createElement('body'); 128 | 129 | if ( parseInt(nodes, 10) ) { 130 | // In order not to give false positives we create a node for each test 131 | // This also allows the method to scale for unspecified uses 132 | while ( nodes-- ) { 133 | node = document.createElement('div'); 134 | node.id = testnames ? testnames[nodes] : mod + (nodes + 1); 135 | div.appendChild(node); 136 | } 137 | } 138 | 139 | // '].join(''); 145 | div.id = mod; 146 | // IE6 will false positive on some tests due to the style element inside the test div somehow interfering offsetHeight, so insert it into body or fakebody. 147 | // Opera will act all quirky when injecting elements in documentElement when page is served as xml, needs fakebody too. #270 148 | (body ? div : fakeBody).innerHTML += style; 149 | fakeBody.appendChild(div); 150 | if ( !body ) { 151 | //avoid crashing IE8, if background image is used 152 | fakeBody.style.background = ''; 153 | //Safari 5.13/5.1.4 OSX stops loading if ::-webkit-scrollbar is used and scrollbars are visible 154 | fakeBody.style.overflow = 'hidden'; 155 | docOverflow = docElement.style.overflow; 156 | docElement.style.overflow = 'hidden'; 157 | docElement.appendChild(fakeBody); 158 | } 159 | 160 | ret = callback(div, rule); 161 | // If this is done after page load we don't want to remove the body so check if body exists 162 | if ( !body ) { 163 | fakeBody.parentNode.removeChild(fakeBody); 164 | docElement.style.overflow = docOverflow; 165 | } else { 166 | div.parentNode.removeChild(div); 167 | } 168 | 169 | return !!ret; 170 | 171 | }, 172 | /*>>teststyles*/ 173 | 174 | /*>>mq*/ 175 | // adapted from matchMedia polyfill 176 | // by Scott Jehl and Paul Irish 177 | // gist.github.com/786768 178 | testMediaQuery = function( mq ) { 179 | 180 | var matchMedia = window.matchMedia || window.msMatchMedia; 181 | if ( matchMedia ) { 182 | return matchMedia(mq).matches; 183 | } 184 | 185 | var bool; 186 | 187 | injectElementWithStyles('@media ' + mq + ' { #' + mod + ' { position: absolute; } }', function( node ) { 188 | bool = (window.getComputedStyle ? 189 | getComputedStyle(node, null) : 190 | node.currentStyle)['position'] == 'absolute'; 191 | }); 192 | 193 | return bool; 194 | 195 | }, 196 | /*>>mq*/ 197 | 198 | 199 | /*>>hasevent*/ 200 | // 201 | // isEventSupported determines if a given element supports the given event 202 | // kangax.github.com/iseventsupported/ 203 | // 204 | // The following results are known incorrects: 205 | // Modernizr.hasEvent("webkitTransitionEnd", elem) // false negative 206 | // Modernizr.hasEvent("textInput") // in Webkit. github.com/Modernizr/Modernizr/issues/333 207 | // ... 208 | isEventSupported = (function() { 209 | 210 | var TAGNAMES = { 211 | 'select': 'input', 'change': 'input', 212 | 'submit': 'form', 'reset': 'form', 213 | 'error': 'img', 'load': 'img', 'abort': 'img' 214 | }; 215 | 216 | function isEventSupported( eventName, element ) { 217 | 218 | element = element || document.createElement(TAGNAMES[eventName] || 'div'); 219 | eventName = 'on' + eventName; 220 | 221 | // When using `setAttribute`, IE skips "unload", WebKit skips "unload" and "resize", whereas `in` "catches" those 222 | var isSupported = eventName in element; 223 | 224 | if ( !isSupported ) { 225 | // If it has no `setAttribute` (i.e. doesn't implement Node interface), try generic element 226 | if ( !element.setAttribute ) { 227 | element = document.createElement('div'); 228 | } 229 | if ( element.setAttribute && element.removeAttribute ) { 230 | element.setAttribute(eventName, ''); 231 | isSupported = is(element[eventName], 'function'); 232 | 233 | // If property was created, "remove it" (by setting value to `undefined`) 234 | if ( !is(element[eventName], 'undefined') ) { 235 | element[eventName] = undefined; 236 | } 237 | element.removeAttribute(eventName); 238 | } 239 | } 240 | 241 | element = null; 242 | return isSupported; 243 | } 244 | return isEventSupported; 245 | })(), 246 | /*>>hasevent*/ 247 | 248 | // TODO :: Add flag for hasownprop ? didn't last time 249 | 250 | // hasOwnProperty shim by kangax needed for Safari 2.0 support 251 | _hasOwnProperty = ({}).hasOwnProperty, hasOwnProp; 252 | 253 | if ( !is(_hasOwnProperty, 'undefined') && !is(_hasOwnProperty.call, 'undefined') ) { 254 | hasOwnProp = function (object, property) { 255 | return _hasOwnProperty.call(object, property); 256 | }; 257 | } 258 | else { 259 | hasOwnProp = function (object, property) { /* yes, this can give false positives/negatives, but most of the time we don't care about those */ 260 | return ((property in object) && is(object.constructor.prototype[property], 'undefined')); 261 | }; 262 | } 263 | 264 | // Adapted from ES5-shim https://github.com/kriskowal/es5-shim/blob/master/es5-shim.js 265 | // es5.github.com/#x15.3.4.5 266 | 267 | if (!Function.prototype.bind) { 268 | Function.prototype.bind = function bind(that) { 269 | 270 | var target = this; 271 | 272 | if (typeof target != "function") { 273 | throw new TypeError(); 274 | } 275 | 276 | var args = slice.call(arguments, 1), 277 | bound = function () { 278 | 279 | if (this instanceof bound) { 280 | 281 | var F = function(){}; 282 | F.prototype = target.prototype; 283 | var self = new F(); 284 | 285 | var result = target.apply( 286 | self, 287 | args.concat(slice.call(arguments)) 288 | ); 289 | if (Object(result) === result) { 290 | return result; 291 | } 292 | return self; 293 | 294 | } else { 295 | 296 | return target.apply( 297 | that, 298 | args.concat(slice.call(arguments)) 299 | ); 300 | 301 | } 302 | 303 | }; 304 | 305 | return bound; 306 | }; 307 | } 308 | 309 | /** 310 | * setCss applies given styles to the Modernizr DOM node. 311 | */ 312 | function setCss( str ) { 313 | mStyle.cssText = str; 314 | } 315 | 316 | /** 317 | * setCssAll extrapolates all vendor-specific css strings. 318 | */ 319 | function setCssAll( str1, str2 ) { 320 | return setCss(prefixes.join(str1 + ';') + ( str2 || '' )); 321 | } 322 | 323 | /** 324 | * is returns a boolean for if typeof obj is exactly type. 325 | */ 326 | function is( obj, type ) { 327 | return typeof obj === type; 328 | } 329 | 330 | /** 331 | * contains returns a boolean for if substr is found within str. 332 | */ 333 | function contains( str, substr ) { 334 | return !!~('' + str).indexOf(substr); 335 | } 336 | 337 | /*>>testprop*/ 338 | 339 | // testProps is a generic CSS / DOM property test. 340 | 341 | // In testing support for a given CSS property, it's legit to test: 342 | // `elem.style[styleName] !== undefined` 343 | // If the property is supported it will return an empty string, 344 | // if unsupported it will return undefined. 345 | 346 | // We'll take advantage of this quick test and skip setting a style 347 | // on our modernizr element, but instead just testing undefined vs 348 | // empty string. 349 | 350 | // Because the testing of the CSS property names (with "-", as 351 | // opposed to the camelCase DOM properties) is non-portable and 352 | // non-standard but works in WebKit and IE (but not Gecko or Opera), 353 | // we explicitly reject properties with dashes so that authors 354 | // developing in WebKit or IE first don't end up with 355 | // browser-specific content by accident. 356 | 357 | function testProps( props, prefixed ) { 358 | for ( var i in props ) { 359 | var prop = props[i]; 360 | if ( !contains(prop, "-") && mStyle[prop] !== undefined ) { 361 | return prefixed == 'pfx' ? prop : true; 362 | } 363 | } 364 | return false; 365 | } 366 | /*>>testprop*/ 367 | 368 | // TODO :: add testDOMProps 369 | /** 370 | * testDOMProps is a generic DOM property test; if a browser supports 371 | * a certain property, it won't return undefined for it. 372 | */ 373 | function testDOMProps( props, obj, elem ) { 374 | for ( var i in props ) { 375 | var item = obj[props[i]]; 376 | if ( item !== undefined) { 377 | 378 | // return the property name as a string 379 | if (elem === false) return props[i]; 380 | 381 | // let's bind a function 382 | if (is(item, 'function')){ 383 | // default to autobind unless override 384 | return item.bind(elem || obj); 385 | } 386 | 387 | // return the unbound function or obj or value 388 | return item; 389 | } 390 | } 391 | return false; 392 | } 393 | 394 | /*>>testallprops*/ 395 | /** 396 | * testPropsAll tests a list of DOM properties we want to check against. 397 | * We specify literally ALL possible (known and/or likely) properties on 398 | * the element including the non-vendor prefixed one, for forward- 399 | * compatibility. 400 | */ 401 | function testPropsAll( prop, prefixed, elem ) { 402 | 403 | var ucProp = prop.charAt(0).toUpperCase() + prop.slice(1), 404 | props = (prop + ' ' + cssomPrefixes.join(ucProp + ' ') + ucProp).split(' '); 405 | 406 | // did they call .prefixed('boxSizing') or are we just testing a prop? 407 | if(is(prefixed, "string") || is(prefixed, "undefined")) { 408 | return testProps(props, prefixed); 409 | 410 | // otherwise, they called .prefixed('requestAnimationFrame', window[, elem]) 411 | } else { 412 | props = (prop + ' ' + (domPrefixes).join(ucProp + ' ') + ucProp).split(' '); 413 | return testDOMProps(props, prefixed, elem); 414 | } 415 | } 416 | /*>>testallprops*/ 417 | 418 | 419 | /** 420 | * Tests 421 | * ----- 422 | */ 423 | 424 | // The *new* flexbox 425 | // dev.w3.org/csswg/css3-flexbox 426 | 427 | tests['flexbox'] = function() { 428 | return testPropsAll('flexWrap'); 429 | }; 430 | 431 | // The *old* flexbox 432 | // www.w3.org/TR/2009/WD-css3-flexbox-20090723/ 433 | 434 | tests['flexboxlegacy'] = function() { 435 | return testPropsAll('boxDirection'); 436 | }; 437 | 438 | // On the S60 and BB Storm, getContext exists, but always returns undefined 439 | // so we actually have to call getContext() to verify 440 | // github.com/Modernizr/Modernizr/issues/issue/97/ 441 | 442 | tests['canvas'] = function() { 443 | var elem = document.createElement('canvas'); 444 | return !!(elem.getContext && elem.getContext('2d')); 445 | }; 446 | 447 | tests['canvastext'] = function() { 448 | return !!(Modernizr['canvas'] && is(document.createElement('canvas').getContext('2d').fillText, 'function')); 449 | }; 450 | 451 | // webk.it/70117 is tracking a legit WebGL feature detect proposal 452 | 453 | // We do a soft detect which may false positive in order to avoid 454 | // an expensive context creation: bugzil.la/732441 455 | 456 | tests['webgl'] = function() { 457 | return !!window.WebGLRenderingContext; 458 | }; 459 | 460 | /* 461 | * The Modernizr.touch test only indicates if the browser supports 462 | * touch events, which does not necessarily reflect a touchscreen 463 | * device, as evidenced by tablets running Windows 7 or, alas, 464 | * the Palm Pre / WebOS (touch) phones. 465 | * 466 | * Additionally, Chrome (desktop) used to lie about its support on this, 467 | * but that has since been rectified: crbug.com/36415 468 | * 469 | * We also test for Firefox 4 Multitouch Support. 470 | * 471 | * For more info, see: modernizr.github.com/Modernizr/touch.html 472 | */ 473 | 474 | tests['touch'] = function() { 475 | var bool; 476 | 477 | if(('ontouchstart' in window) || window.DocumentTouch && document instanceof DocumentTouch) { 478 | bool = true; 479 | } else { 480 | injectElementWithStyles(['@media (',prefixes.join('touch-enabled),('),mod,')','{#modernizr{top:9px;position:absolute}}'].join(''), function( node ) { 481 | bool = node.offsetTop === 9; 482 | }); 483 | } 484 | 485 | return bool; 486 | }; 487 | 488 | 489 | // geolocation is often considered a trivial feature detect... 490 | // Turns out, it's quite tricky to get right: 491 | // 492 | // Using !!navigator.geolocation does two things we don't want. It: 493 | // 1. Leaks memory in IE9: github.com/Modernizr/Modernizr/issues/513 494 | // 2. Disables page caching in WebKit: webk.it/43956 495 | // 496 | // Meanwhile, in Firefox < 8, an about:config setting could expose 497 | // a false positive that would throw an exception: bugzil.la/688158 498 | 499 | tests['geolocation'] = function() { 500 | return 'geolocation' in navigator; 501 | }; 502 | 503 | 504 | tests['postmessage'] = function() { 505 | return !!window.postMessage; 506 | }; 507 | 508 | 509 | // Chrome incognito mode used to throw an exception when using openDatabase 510 | // It doesn't anymore. 511 | tests['websqldatabase'] = function() { 512 | return !!window.openDatabase; 513 | }; 514 | 515 | // Vendors had inconsistent prefixing with the experimental Indexed DB: 516 | // - Webkit's implementation is accessible through webkitIndexedDB 517 | // - Firefox shipped moz_indexedDB before FF4b9, but since then has been mozIndexedDB 518 | // For speed, we don't test the legacy (and beta-only) indexedDB 519 | tests['indexedDB'] = function() { 520 | return !!testPropsAll("indexedDB", window); 521 | }; 522 | 523 | // documentMode logic from YUI to filter out IE8 Compat Mode 524 | // which false positives. 525 | tests['hashchange'] = function() { 526 | return isEventSupported('hashchange', window) && (document.documentMode === undefined || document.documentMode > 7); 527 | }; 528 | 529 | // Per 1.6: 530 | // This used to be Modernizr.historymanagement but the longer 531 | // name has been deprecated in favor of a shorter and property-matching one. 532 | // The old API is still available in 1.6, but as of 2.0 will throw a warning, 533 | // and in the first release thereafter disappear entirely. 534 | tests['history'] = function() { 535 | return !!(window.history && history.pushState); 536 | }; 537 | 538 | tests['draganddrop'] = function() { 539 | var div = document.createElement('div'); 540 | return ('draggable' in div) || ('ondragstart' in div && 'ondrop' in div); 541 | }; 542 | 543 | // FF3.6 was EOL'ed on 4/24/12, but the ESR version of FF10 544 | // will be supported until FF19 (2/12/13), at which time, ESR becomes FF17. 545 | // FF10 still uses prefixes, so check for it until then. 546 | // for more ESR info, see: mozilla.org/en-US/firefox/organizations/faq/ 547 | tests['websockets'] = function() { 548 | return 'WebSocket' in window || 'MozWebSocket' in window; 549 | }; 550 | 551 | 552 | // css-tricks.com/rgba-browser-support/ 553 | tests['rgba'] = function() { 554 | // Set an rgba() color and check the returned value 555 | 556 | setCss('background-color:rgba(150,255,150,.5)'); 557 | 558 | return contains(mStyle.backgroundColor, 'rgba'); 559 | }; 560 | 561 | tests['hsla'] = function() { 562 | // Same as rgba(), in fact, browsers re-map hsla() to rgba() internally, 563 | // except IE9 who retains it as hsla 564 | 565 | setCss('background-color:hsla(120,40%,100%,.5)'); 566 | 567 | return contains(mStyle.backgroundColor, 'rgba') || contains(mStyle.backgroundColor, 'hsla'); 568 | }; 569 | 570 | tests['multiplebgs'] = function() { 571 | // Setting multiple images AND a color on the background shorthand property 572 | // and then querying the style.background property value for the number of 573 | // occurrences of "url(" is a reliable method for detecting ACTUAL support for this! 574 | 575 | setCss('background:url(https://),url(https://),red url(https://)'); 576 | 577 | // If the UA supports multiple backgrounds, there should be three occurrences 578 | // of the string "url(" in the return value for elemStyle.background 579 | 580 | return (/(url\s*\(.*?){3}/).test(mStyle.background); 581 | }; 582 | 583 | 584 | 585 | // this will false positive in Opera Mini 586 | // github.com/Modernizr/Modernizr/issues/396 587 | 588 | tests['backgroundsize'] = function() { 589 | return testPropsAll('backgroundSize'); 590 | }; 591 | 592 | tests['borderimage'] = function() { 593 | return testPropsAll('borderImage'); 594 | }; 595 | 596 | 597 | // Super comprehensive table about all the unique implementations of 598 | // border-radius: muddledramblings.com/table-of-css3-border-radius-compliance 599 | 600 | tests['borderradius'] = function() { 601 | return testPropsAll('borderRadius'); 602 | }; 603 | 604 | // WebOS unfortunately false positives on this test. 605 | tests['boxshadow'] = function() { 606 | return testPropsAll('boxShadow'); 607 | }; 608 | 609 | // FF3.0 will false positive on this test 610 | tests['textshadow'] = function() { 611 | return document.createElement('div').style.textShadow === ''; 612 | }; 613 | 614 | 615 | tests['opacity'] = function() { 616 | // Browsers that actually have CSS Opacity implemented have done so 617 | // according to spec, which means their return values are within the 618 | // range of [0.0,1.0] - including the leading zero. 619 | 620 | setCssAll('opacity:.55'); 621 | 622 | // The non-literal . in this regex is intentional: 623 | // German Chrome returns this value as 0,55 624 | // github.com/Modernizr/Modernizr/issues/#issue/59/comment/516632 625 | return (/^0.55$/).test(mStyle.opacity); 626 | }; 627 | 628 | 629 | // Note, Android < 4 will pass this test, but can only animate 630 | // a single property at a time 631 | // daneden.me/2011/12/putting-up-with-androids-bullshit/ 632 | tests['cssanimations'] = function() { 633 | return testPropsAll('animationName'); 634 | }; 635 | 636 | 637 | tests['csscolumns'] = function() { 638 | return testPropsAll('columnCount'); 639 | }; 640 | 641 | 642 | tests['cssgradients'] = function() { 643 | /** 644 | * For CSS Gradients syntax, please see: 645 | * webkit.org/blog/175/introducing-css-gradients/ 646 | * developer.mozilla.org/en/CSS/-moz-linear-gradient 647 | * developer.mozilla.org/en/CSS/-moz-radial-gradient 648 | * dev.w3.org/csswg/css3-images/#gradients- 649 | */ 650 | 651 | var str1 = 'background-image:', 652 | str2 = 'gradient(linear,left top,right bottom,from(#9f9),to(white));', 653 | str3 = 'linear-gradient(left top,#9f9, white);'; 654 | 655 | setCss( 656 | // legacy webkit syntax (FIXME: remove when syntax not in use anymore) 657 | (str1 + '-webkit- '.split(' ').join(str2 + str1) + 658 | // standard syntax // trailing 'background-image:' 659 | prefixes.join(str3 + str1)).slice(0, -str1.length) 660 | ); 661 | 662 | return contains(mStyle.backgroundImage, 'gradient'); 663 | }; 664 | 665 | 666 | tests['cssreflections'] = function() { 667 | return testPropsAll('boxReflect'); 668 | }; 669 | 670 | 671 | tests['csstransforms'] = function() { 672 | return !!testPropsAll('transform'); 673 | }; 674 | 675 | 676 | tests['csstransforms3d'] = function() { 677 | 678 | var ret = !!testPropsAll('perspective'); 679 | 680 | // Webkit's 3D transforms are passed off to the browser's own graphics renderer. 681 | // It works fine in Safari on Leopard and Snow Leopard, but not in Chrome in 682 | // some conditions. As a result, Webkit typically recognizes the syntax but 683 | // will sometimes throw a false positive, thus we must do a more thorough check: 684 | if ( ret && 'webkitPerspective' in docElement.style ) { 685 | 686 | // Webkit allows this media query to succeed only if the feature is enabled. 687 | // `@media (transform-3d),(-webkit-transform-3d){ ... }` 688 | injectElementWithStyles('@media (transform-3d),(-webkit-transform-3d){#modernizr{left:9px;position:absolute;height:3px;}}', function( node, rule ) { 689 | ret = node.offsetLeft === 9 && node.offsetHeight === 3; 690 | }); 691 | } 692 | return ret; 693 | }; 694 | 695 | 696 | tests['csstransitions'] = function() { 697 | return testPropsAll('transition'); 698 | }; 699 | 700 | 701 | /*>>fontface*/ 702 | // @font-face detection routine by Diego Perini 703 | // javascript.nwbox.com/CSSSupport/ 704 | 705 | // false positives: 706 | // WebOS github.com/Modernizr/Modernizr/issues/342 707 | // WP7 github.com/Modernizr/Modernizr/issues/538 708 | tests['fontface'] = function() { 709 | var bool; 710 | 711 | injectElementWithStyles('@font-face {font-family:"font";src:url("https://")}', function( node, rule ) { 712 | var style = document.getElementById('smodernizr'), 713 | sheet = style.sheet || style.styleSheet, 714 | cssText = sheet ? (sheet.cssRules && sheet.cssRules[0] ? sheet.cssRules[0].cssText : sheet.cssText || '') : ''; 715 | 716 | bool = /src/i.test(cssText) && cssText.indexOf(rule.split(' ')[0]) === 0; 717 | }); 718 | 719 | return bool; 720 | }; 721 | /*>>fontface*/ 722 | 723 | // CSS generated content detection 724 | tests['generatedcontent'] = function() { 725 | var bool; 726 | 727 | injectElementWithStyles(['#',mod,'{font:0/0 a}#',mod,':after{content:"',smile,'";visibility:hidden;font:3px/1 a}'].join(''), function( node ) { 728 | bool = node.offsetHeight >= 3; 729 | }); 730 | 731 | return bool; 732 | }; 733 | 734 | 735 | 736 | // These tests evaluate support of the video/audio elements, as well as 737 | // testing what types of content they support. 738 | // 739 | // We're using the Boolean constructor here, so that we can extend the value 740 | // e.g. Modernizr.video // true 741 | // Modernizr.video.ogg // 'probably' 742 | // 743 | // Codec values from : github.com/NielsLeenheer/html5test/blob/9106a8/index.html#L845 744 | // thx to NielsLeenheer and zcorpan 745 | 746 | // Note: in some older browsers, "no" was a return value instead of empty string. 747 | // It was live in FF3.5.0 and 3.5.1, but fixed in 3.5.2 748 | // It was also live in Safari 4.0.0 - 4.0.4, but fixed in 4.0.5 749 | 750 | tests['video'] = function() { 751 | var elem = document.createElement('video'), 752 | bool = false; 753 | 754 | // IE9 Running on Windows Server SKU can cause an exception to be thrown, bug #224 755 | try { 756 | if ( bool = !!elem.canPlayType ) { 757 | bool = new Boolean(bool); 758 | bool.ogg = elem.canPlayType('video/ogg; codecs="theora"') .replace(/^no$/,''); 759 | 760 | // Without QuickTime, this value will be `undefined`. github.com/Modernizr/Modernizr/issues/546 761 | bool.h264 = elem.canPlayType('video/mp4; codecs="avc1.42E01E"') .replace(/^no$/,''); 762 | 763 | bool.webm = elem.canPlayType('video/webm; codecs="vp8, vorbis"').replace(/^no$/,''); 764 | } 765 | 766 | } catch(e) { } 767 | 768 | return bool; 769 | }; 770 | 771 | tests['audio'] = function() { 772 | var elem = document.createElement('audio'), 773 | bool = false; 774 | 775 | try { 776 | if ( bool = !!elem.canPlayType ) { 777 | bool = new Boolean(bool); 778 | bool.ogg = elem.canPlayType('audio/ogg; codecs="vorbis"').replace(/^no$/,''); 779 | bool.mp3 = elem.canPlayType('audio/mpeg;') .replace(/^no$/,''); 780 | 781 | // Mimetypes accepted: 782 | // developer.mozilla.org/En/Media_formats_supported_by_the_audio_and_video_elements 783 | // bit.ly/iphoneoscodecs 784 | bool.wav = elem.canPlayType('audio/wav; codecs="1"') .replace(/^no$/,''); 785 | bool.m4a = ( elem.canPlayType('audio/x-m4a;') || 786 | elem.canPlayType('audio/aac;')) .replace(/^no$/,''); 787 | } 788 | } catch(e) { } 789 | 790 | return bool; 791 | }; 792 | 793 | 794 | // In FF4, if disabled, window.localStorage should === null. 795 | 796 | // Normally, we could not test that directly and need to do a 797 | // `('localStorage' in window) && ` test first because otherwise Firefox will 798 | // throw bugzil.la/365772 if cookies are disabled 799 | 800 | // Also in iOS5 Private Browsing mode, attempting to use localStorage.setItem 801 | // will throw the exception: 802 | // QUOTA_EXCEEDED_ERRROR DOM Exception 22. 803 | // Peculiarly, getItem and removeItem calls do not throw. 804 | 805 | // Because we are forced to try/catch this, we'll go aggressive. 806 | 807 | // Just FWIW: IE8 Compat mode supports these features completely: 808 | // www.quirksmode.org/dom/html5.html 809 | // But IE8 doesn't support either with local files 810 | 811 | tests['localstorage'] = function() { 812 | try { 813 | localStorage.setItem(mod, mod); 814 | localStorage.removeItem(mod); 815 | return true; 816 | } catch(e) { 817 | return false; 818 | } 819 | }; 820 | 821 | tests['sessionstorage'] = function() { 822 | try { 823 | sessionStorage.setItem(mod, mod); 824 | sessionStorage.removeItem(mod); 825 | return true; 826 | } catch(e) { 827 | return false; 828 | } 829 | }; 830 | 831 | 832 | tests['webworkers'] = function() { 833 | return !!window.Worker; 834 | }; 835 | 836 | 837 | tests['applicationcache'] = function() { 838 | return !!window.applicationCache; 839 | }; 840 | 841 | 842 | // Thanks to Erik Dahlstrom 843 | tests['svg'] = function() { 844 | return !!document.createElementNS && !!document.createElementNS(ns.svg, 'svg').createSVGRect; 845 | }; 846 | 847 | // specifically for SVG inline in HTML, not within XHTML 848 | // test page: paulirish.com/demo/inline-svg 849 | tests['inlinesvg'] = function() { 850 | var div = document.createElement('div'); 851 | div.innerHTML = ''; 852 | return (div.firstChild && div.firstChild.namespaceURI) == ns.svg; 853 | }; 854 | 855 | // SVG SMIL animation 856 | tests['smil'] = function() { 857 | return !!document.createElementNS && /SVGAnimate/.test(toString.call(document.createElementNS(ns.svg, 'animate'))); 858 | }; 859 | 860 | // This test is only for clip paths in SVG proper, not clip paths on HTML content 861 | // demo: srufaculty.sru.edu/david.dailey/svg/newstuff/clipPath4.svg 862 | 863 | // However read the comments to dig into applying SVG clippaths to HTML content here: 864 | // github.com/Modernizr/Modernizr/issues/213#issuecomment-1149491 865 | tests['svgclippaths'] = function() { 866 | return !!document.createElementNS && /SVGClipPath/.test(toString.call(document.createElementNS(ns.svg, 'clipPath'))); 867 | }; 868 | 869 | /*>>webforms*/ 870 | // input features and input types go directly onto the ret object, bypassing the tests loop. 871 | // Hold this guy to execute in a moment. 872 | function webforms() { 873 | /*>>input*/ 874 | // Run through HTML5's new input attributes to see if the UA understands any. 875 | // We're using f which is the element created early on 876 | // Mike Taylr has created a comprehensive resource for testing these attributes 877 | // when applied to all input types: 878 | // miketaylr.com/code/input-type-attr.html 879 | // spec: www.whatwg.org/specs/web-apps/current-work/multipage/the-input-element.html#input-type-attr-summary 880 | 881 | // Only input placeholder is tested while textarea's placeholder is not. 882 | // Currently Safari 4 and Opera 11 have support only for the input placeholder 883 | // Both tests are available in feature-detects/forms-placeholder.js 884 | Modernizr['input'] = (function( props ) { 885 | for ( var i = 0, len = props.length; i < len; i++ ) { 886 | attrs[ props[i] ] = !!(props[i] in inputElem); 887 | } 888 | if (attrs.list){ 889 | // safari false positive's on datalist: webk.it/74252 890 | // see also github.com/Modernizr/Modernizr/issues/146 891 | attrs.list = !!(document.createElement('datalist') && window.HTMLDataListElement); 892 | } 893 | return attrs; 894 | })('autocomplete autofocus list placeholder max min multiple pattern required step'.split(' ')); 895 | /*>>input*/ 896 | 897 | /*>>inputtypes*/ 898 | // Run through HTML5's new input types to see if the UA understands any. 899 | // This is put behind the tests runloop because it doesn't return a 900 | // true/false like all the other tests; instead, it returns an object 901 | // containing each input type with its corresponding true/false value 902 | 903 | // Big thanks to @miketaylr for the html5 forms expertise. miketaylr.com/ 904 | Modernizr['inputtypes'] = (function(props) { 905 | 906 | for ( var i = 0, bool, inputElemType, defaultView, len = props.length; i < len; i++ ) { 907 | 908 | inputElem.setAttribute('type', inputElemType = props[i]); 909 | bool = inputElem.type !== 'text'; 910 | 911 | // We first check to see if the type we give it sticks.. 912 | // If the type does, we feed it a textual value, which shouldn't be valid. 913 | // If the value doesn't stick, we know there's input sanitization which infers a custom UI 914 | if ( bool ) { 915 | 916 | inputElem.value = smile; 917 | inputElem.style.cssText = 'position:absolute;visibility:hidden;'; 918 | 919 | if ( /^range$/.test(inputElemType) && inputElem.style.WebkitAppearance !== undefined ) { 920 | 921 | docElement.appendChild(inputElem); 922 | defaultView = document.defaultView; 923 | 924 | // Safari 2-4 allows the smiley as a value, despite making a slider 925 | bool = defaultView.getComputedStyle && 926 | defaultView.getComputedStyle(inputElem, null).WebkitAppearance !== 'textfield' && 927 | // Mobile android web browser has false positive, so must 928 | // check the height to see if the widget is actually there. 929 | (inputElem.offsetHeight !== 0); 930 | 931 | docElement.removeChild(inputElem); 932 | 933 | } else if ( /^(search|tel)$/.test(inputElemType) ){ 934 | // Spec doesn't define any special parsing or detectable UI 935 | // behaviors so we pass these through as true 936 | 937 | // Interestingly, opera fails the earlier test, so it doesn't 938 | // even make it here. 939 | 940 | } else if ( /^(url|email)$/.test(inputElemType) ) { 941 | // Real url and email support comes with prebaked validation. 942 | bool = inputElem.checkValidity && inputElem.checkValidity() === false; 943 | 944 | } else { 945 | // If the upgraded input compontent rejects the :) text, we got a winner 946 | bool = inputElem.value != smile; 947 | } 948 | } 949 | 950 | inputs[ props[i] ] = !!bool; 951 | } 952 | return inputs; 953 | })('search tel url email datetime date month week time datetime-local number range color'.split(' ')); 954 | /*>>inputtypes*/ 955 | } 956 | /*>>webforms*/ 957 | 958 | 959 | // End of test definitions 960 | // ----------------------- 961 | 962 | 963 | 964 | // Run through all tests and detect their support in the current UA. 965 | // todo: hypothetically we could be doing an array of tests and use a basic loop here. 966 | for ( var feature in tests ) { 967 | if ( hasOwnProp(tests, feature) ) { 968 | // run the test, throw the return value into the Modernizr, 969 | // then based on that boolean, define an appropriate className 970 | // and push it into an array of classes we'll join later. 971 | featureName = feature.toLowerCase(); 972 | Modernizr[featureName] = tests[feature](); 973 | 974 | classes.push((Modernizr[featureName] ? '' : 'no-') + featureName); 975 | } 976 | } 977 | 978 | /*>>webforms*/ 979 | // input tests need to run. 980 | Modernizr.input || webforms(); 981 | /*>>webforms*/ 982 | 983 | 984 | /** 985 | * addTest allows the user to define their own feature tests 986 | * the result will be added onto the Modernizr object, 987 | * as well as an appropriate className set on the html element 988 | * 989 | * @param feature - String naming the feature 990 | * @param test - Function returning true if feature is supported, false if not 991 | */ 992 | Modernizr.addTest = function ( feature, test ) { 993 | if ( typeof feature == 'object' ) { 994 | for ( var key in feature ) { 995 | if ( hasOwnProp( feature, key ) ) { 996 | Modernizr.addTest( key, feature[ key ] ); 997 | } 998 | } 999 | } else { 1000 | 1001 | feature = feature.toLowerCase(); 1002 | 1003 | if ( Modernizr[feature] !== undefined ) { 1004 | // we're going to quit if you're trying to overwrite an existing test 1005 | // if we were to allow it, we'd do this: 1006 | // var re = new RegExp("\\b(no-)?" + feature + "\\b"); 1007 | // docElement.className = docElement.className.replace( re, '' ); 1008 | // but, no rly, stuff 'em. 1009 | return Modernizr; 1010 | } 1011 | 1012 | test = typeof test == 'function' ? test() : test; 1013 | 1014 | if (typeof enableClasses !== "undefined" && enableClasses) { 1015 | docElement.className += ' ' + (test ? '' : 'no-') + feature; 1016 | } 1017 | Modernizr[feature] = test; 1018 | 1019 | } 1020 | 1021 | return Modernizr; // allow chaining. 1022 | }; 1023 | 1024 | 1025 | // Reset modElem.cssText to nothing to reduce memory footprint. 1026 | setCss(''); 1027 | modElem = inputElem = null; 1028 | 1029 | /*>>shiv*/ 1030 | /*! HTML5 Shiv v3.6.1 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed */ 1031 | ;(function(window, document) { 1032 | /*jshint evil:true */ 1033 | /** Preset options */ 1034 | var options = window.html5 || {}; 1035 | 1036 | /** Used to skip problem elements */ 1037 | var reSkip = /^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i; 1038 | 1039 | /** Not all elements can be cloned in IE **/ 1040 | var saveClones = /^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i; 1041 | 1042 | /** Detect whether the browser supports default html5 styles */ 1043 | var supportsHtml5Styles; 1044 | 1045 | /** Name of the expando, to work with multiple documents or to re-shiv one document */ 1046 | var expando = '_html5shiv'; 1047 | 1048 | /** The id for the the documents expando */ 1049 | var expanID = 0; 1050 | 1051 | /** Cached data for each document */ 1052 | var expandoData = {}; 1053 | 1054 | /** Detect whether the browser supports unknown elements */ 1055 | var supportsUnknownElements; 1056 | 1057 | (function() { 1058 | try { 1059 | var a = document.createElement('a'); 1060 | a.innerHTML = ''; 1061 | //if the hidden property is implemented we can assume, that the browser supports basic HTML5 Styles 1062 | supportsHtml5Styles = ('hidden' in a); 1063 | 1064 | supportsUnknownElements = a.childNodes.length == 1 || (function() { 1065 | // assign a false positive if unable to shiv 1066 | (document.createElement)('a'); 1067 | var frag = document.createDocumentFragment(); 1068 | return ( 1069 | typeof frag.cloneNode == 'undefined' || 1070 | typeof frag.createDocumentFragment == 'undefined' || 1071 | typeof frag.createElement == 'undefined' 1072 | ); 1073 | }()); 1074 | } catch(e) { 1075 | supportsHtml5Styles = true; 1076 | supportsUnknownElements = true; 1077 | } 1078 | 1079 | }()); 1080 | 1081 | /*--------------------------------------------------------------------------*/ 1082 | 1083 | /** 1084 | * Creates a style sheet with the given CSS text and adds it to the document. 1085 | * @private 1086 | * @param {Document} ownerDocument The document. 1087 | * @param {String} cssText The CSS text. 1088 | * @returns {StyleSheet} The style element. 1089 | */ 1090 | function addStyleSheet(ownerDocument, cssText) { 1091 | var p = ownerDocument.createElement('p'), 1092 | parent = ownerDocument.getElementsByTagName('head')[0] || ownerDocument.documentElement; 1093 | 1094 | p.innerHTML = 'x'; 1095 | return parent.insertBefore(p.lastChild, parent.firstChild); 1096 | } 1097 | 1098 | /** 1099 | * Returns the value of `html5.elements` as an array. 1100 | * @private 1101 | * @returns {Array} An array of shived element node names. 1102 | */ 1103 | function getElements() { 1104 | var elements = html5.elements; 1105 | return typeof elements == 'string' ? elements.split(' ') : elements; 1106 | } 1107 | 1108 | /** 1109 | * Returns the data associated to the given document 1110 | * @private 1111 | * @param {Document} ownerDocument The document. 1112 | * @returns {Object} An object of data. 1113 | */ 1114 | function getExpandoData(ownerDocument) { 1115 | var data = expandoData[ownerDocument[expando]]; 1116 | if (!data) { 1117 | data = {}; 1118 | expanID++; 1119 | ownerDocument[expando] = expanID; 1120 | expandoData[expanID] = data; 1121 | } 1122 | return data; 1123 | } 1124 | 1125 | /** 1126 | * returns a shived element for the given nodeName and document 1127 | * @memberOf html5 1128 | * @param {String} nodeName name of the element 1129 | * @param {Document} ownerDocument The context document. 1130 | * @returns {Object} The shived element. 1131 | */ 1132 | function createElement(nodeName, ownerDocument, data){ 1133 | if (!ownerDocument) { 1134 | ownerDocument = document; 1135 | } 1136 | if(supportsUnknownElements){ 1137 | return ownerDocument.createElement(nodeName); 1138 | } 1139 | if (!data) { 1140 | data = getExpandoData(ownerDocument); 1141 | } 1142 | var node; 1143 | 1144 | if (data.cache[nodeName]) { 1145 | node = data.cache[nodeName].cloneNode(); 1146 | } else if (saveClones.test(nodeName)) { 1147 | node = (data.cache[nodeName] = data.createElem(nodeName)).cloneNode(); 1148 | } else { 1149 | node = data.createElem(nodeName); 1150 | } 1151 | 1152 | // Avoid adding some elements to fragments in IE < 9 because 1153 | // * Attributes like `name` or `type` cannot be set/changed once an element 1154 | // is inserted into a document/fragment 1155 | // * Link elements with `src` attributes that are inaccessible, as with 1156 | // a 403 response, will cause the tab/window to crash 1157 | // * Script elements appended to fragments will execute when their `src` 1158 | // or `text` property is set 1159 | return node.canHaveChildren && !reSkip.test(nodeName) ? data.frag.appendChild(node) : node; 1160 | } 1161 | 1162 | /** 1163 | * returns a shived DocumentFragment for the given document 1164 | * @memberOf html5 1165 | * @param {Document} ownerDocument The context document. 1166 | * @returns {Object} The shived DocumentFragment. 1167 | */ 1168 | function createDocumentFragment(ownerDocument, data){ 1169 | if (!ownerDocument) { 1170 | ownerDocument = document; 1171 | } 1172 | if(supportsUnknownElements){ 1173 | return ownerDocument.createDocumentFragment(); 1174 | } 1175 | data = data || getExpandoData(ownerDocument); 1176 | var clone = data.frag.cloneNode(), 1177 | i = 0, 1178 | elems = getElements(), 1179 | l = elems.length; 1180 | for(;i>shiv*/ 1319 | 1320 | // Assign private properties to the return object with prefix 1321 | Modernizr._version = version; 1322 | 1323 | // expose these for the plugin API. Look in the source for how to join() them against your input 1324 | /*>>prefixes*/ 1325 | Modernizr._prefixes = prefixes; 1326 | /*>>prefixes*/ 1327 | /*>>domprefixes*/ 1328 | Modernizr._domPrefixes = domPrefixes; 1329 | Modernizr._cssomPrefixes = cssomPrefixes; 1330 | /*>>domprefixes*/ 1331 | 1332 | /*>>mq*/ 1333 | // Modernizr.mq tests a given media query, live against the current state of the window 1334 | // A few important notes: 1335 | // * If a browser does not support media queries at all (eg. oldIE) the mq() will always return false 1336 | // * A max-width or orientation query will be evaluated against the current state, which may change later. 1337 | // * You must specify values. Eg. If you are testing support for the min-width media query use: 1338 | // Modernizr.mq('(min-width:0)') 1339 | // usage: 1340 | // Modernizr.mq('only screen and (max-width:768)') 1341 | Modernizr.mq = testMediaQuery; 1342 | /*>>mq*/ 1343 | 1344 | /*>>hasevent*/ 1345 | // Modernizr.hasEvent() detects support for a given event, with an optional element to test on 1346 | // Modernizr.hasEvent('gesturestart', elem) 1347 | Modernizr.hasEvent = isEventSupported; 1348 | /*>>hasevent*/ 1349 | 1350 | /*>>testprop*/ 1351 | // Modernizr.testProp() investigates whether a given style property is recognized 1352 | // Note that the property names must be provided in the camelCase variant. 1353 | // Modernizr.testProp('pointerEvents') 1354 | Modernizr.testProp = function(prop){ 1355 | return testProps([prop]); 1356 | }; 1357 | /*>>testprop*/ 1358 | 1359 | /*>>testallprops*/ 1360 | // Modernizr.testAllProps() investigates whether a given style property, 1361 | // or any of its vendor-prefixed variants, is recognized 1362 | // Note that the property names must be provided in the camelCase variant. 1363 | // Modernizr.testAllProps('boxSizing') 1364 | Modernizr.testAllProps = testPropsAll; 1365 | /*>>testallprops*/ 1366 | 1367 | 1368 | /*>>teststyles*/ 1369 | // Modernizr.testStyles() allows you to add custom styles to the document and test an element afterwards 1370 | // Modernizr.testStyles('#modernizr { position:absolute }', function(elem, rule){ ... }) 1371 | Modernizr.testStyles = injectElementWithStyles; 1372 | /*>>teststyles*/ 1373 | 1374 | 1375 | /*>>prefixed*/ 1376 | // Modernizr.prefixed() returns the prefixed or nonprefixed property name variant of your input 1377 | // Modernizr.prefixed('boxSizing') // 'MozBoxSizing' 1378 | 1379 | // Properties must be passed as dom-style camelcase, rather than `box-sizing` hypentated style. 1380 | // Return values will also be the camelCase variant, if you need to translate that to hypenated style use: 1381 | // 1382 | // str.replace(/([A-Z])/g, function(str,m1){ return '-' + m1.toLowerCase(); }).replace(/^ms-/,'-ms-'); 1383 | 1384 | // If you're trying to ascertain which transition end event to bind to, you might do something like... 1385 | // 1386 | // var transEndEventNames = { 1387 | // 'WebkitTransition' : 'webkitTransitionEnd', 1388 | // 'MozTransition' : 'transitionend', 1389 | // 'OTransition' : 'oTransitionEnd', 1390 | // 'msTransition' : 'MSTransitionEnd', 1391 | // 'transition' : 'transitionend' 1392 | // }, 1393 | // transEndEventName = transEndEventNames[ Modernizr.prefixed('transition') ]; 1394 | 1395 | Modernizr.prefixed = function(prop, obj, elem){ 1396 | if(!obj) { 1397 | return testPropsAll(prop, 'pfx'); 1398 | } else { 1399 | // Testing DOM property e.g. Modernizr.prefixed('requestAnimationFrame', window) // 'mozRequestAnimationFrame' 1400 | return testPropsAll(prop, obj, elem); 1401 | } 1402 | }; 1403 | /*>>prefixed*/ 1404 | 1405 | 1406 | /*>>cssclasses*/ 1407 | // Remove "no-js" class from element, if it exists: 1408 | docElement.className = docElement.className.replace(/(^|\s)no-js(\s|$)/, '$1$2') + 1409 | 1410 | // Add the new classes to the element. 1411 | (enableClasses ? ' js ' + classes.join(' ') : ''); 1412 | /*>>cssclasses*/ 1413 | 1414 | return Modernizr; 1415 | 1416 | })(this, this.document); 1417 | -------------------------------------------------------------------------------- /vue-to-mvc5/Views/web.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 |
7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | -------------------------------------------------------------------------------- /vue-to-mvc5/Web.Debug.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 29 | 30 | -------------------------------------------------------------------------------- /vue-to-mvc5/Web.Release.config: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 17 | 18 | 19 | 30 | 31 | -------------------------------------------------------------------------------- /vue-to-mvc5/Web.config: -------------------------------------------------------------------------------- 1 |  2 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 38 | 41 | 42 | 43 | 44 | -------------------------------------------------------------------------------- /vue-to-mvc5/fonts/glyphicons-halflings-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hyunoosung/vue-to-mvc5/f025d5f091efe851d43a77f49141a4a3f966dea5/vue-to-mvc5/fonts/glyphicons-halflings-regular.eot -------------------------------------------------------------------------------- /vue-to-mvc5/fonts/glyphicons-halflings-regular.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | 71 | 72 | 73 | 74 | 75 | 76 | 77 | 78 | 79 | 80 | 81 | 82 | 83 | 84 | 85 | 86 | 87 | 88 | 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | 152 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | 169 | 170 | 171 | 172 | 173 | 174 | 175 | 176 | 177 | 178 | 179 | 180 | 181 | 182 | 183 | 184 | 185 | 186 | 187 | 188 | 189 | 190 | 191 | 192 | 193 | 194 | 195 | 196 | 197 | 198 | 199 | 200 | 201 | 202 | 203 | 204 | 205 | 206 | 207 | 208 | 209 | 210 | 211 | 212 | 213 | 214 | 215 | 216 | 217 | 218 | 219 | 220 | 221 | 222 | 223 | 224 | 225 | 226 | 227 | 228 | -------------------------------------------------------------------------------- /vue-to-mvc5/fonts/glyphicons-halflings-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hyunoosung/vue-to-mvc5/f025d5f091efe851d43a77f49141a4a3f966dea5/vue-to-mvc5/fonts/glyphicons-halflings-regular.ttf -------------------------------------------------------------------------------- /vue-to-mvc5/fonts/glyphicons-halflings-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/hyunoosung/vue-to-mvc5/f025d5f091efe851d43a77f49141a4a3f966dea5/vue-to-mvc5/fonts/glyphicons-halflings-regular.woff -------------------------------------------------------------------------------- /vue-to-mvc5/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | vue-to-mvc5 6 | 7 | 8 |
9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /vue-to-mvc5/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "vue-to-mvc5", 3 | "description": "A Vue.js project", 4 | "version": "1.0.0", 5 | "author": "Hyounwoo ", 6 | "license": "MIT", 7 | "private": true, 8 | "scripts": { 9 | "dev": "cross-env NODE_ENV=development webpack-dev-server --open --content-base ./app/webroot/app --inline --hot --port 8080", 10 | "build": "cross-env NODE_ENV=production webpack --progress --hide-modules" 11 | }, 12 | "dependencies": { 13 | "vue": "^2.5.11", 14 | "vuetify": "^1.0.7" 15 | }, 16 | "browserslist": [ 17 | "> 1%", 18 | "last 2 versions", 19 | "not ie <= 8" 20 | ], 21 | "devDependencies": { 22 | "babel-core": "^6.26.0", 23 | "babel-loader": "^7.1.2", 24 | "babel-preset-env": "^1.6.0", 25 | "babel-preset-stage-3": "^6.24.1", 26 | "cross-env": "^5.0.5", 27 | "css-loader": "^0.28.7", 28 | "file-loader": "^1.1.4", 29 | "vue-loader": "^13.0.5", 30 | "vue-template-compiler": "^2.4.4", 31 | "webpack": "^3.6.0", 32 | "webpack-dev-server": "^2.9.1" 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /vue-to-mvc5/packages.config: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /vue-to-mvc5/vue-to-mvc5.csproj: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | 6 | 7 | Debug 8 | AnyCPU 9 | 10 | 11 | 2.0 12 | {F6A9A64E-53DC-4B89-B11F-BEE3876A48C7} 13 | {349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc} 14 | Library 15 | Properties 16 | vue_to_mvc5 17 | vue-to-mvc5 18 | v4.5 19 | true 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | true 30 | full 31 | false 32 | bin\ 33 | DEBUG;TRACE 34 | prompt 35 | 4 36 | 37 | 38 | pdbonly 39 | true 40 | bin\ 41 | TRACE 42 | prompt 43 | 4 44 | 45 | 46 | 47 | ..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.0\lib\net45\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.dll 48 | True 49 | 50 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 64 | 65 | 66 | 67 | 68 | 69 | 70 | ..\packages\Microsoft.AspNet.Razor.3.2.3\lib\net45\System.Web.Razor.dll 71 | 72 | 73 | ..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Webpages.dll 74 | 75 | 76 | ..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Webpages.Deployment.dll 77 | 78 | 79 | ..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Webpages.Razor.dll 80 | 81 | 82 | ..\packages\Microsoft.AspNet.Webpages.3.2.3\lib\net45\System.Web.Helpers.dll 83 | 84 | 85 | ..\packages\Microsoft.Web.Infrastructure.1.0.0.0\lib\net40\Microsoft.Web.Infrastructure.dll 86 | 87 | 88 | ..\packages\Microsoft.AspNet.Mvc.5.2.3\lib\net45\System.Web.Mvc.dll 89 | 90 | 91 | 92 | 93 | 94 | 95 | 96 | 97 | 98 | 99 | 100 | 101 | 102 | 103 | 104 | 105 | 106 | 107 | 108 | 109 | 110 | 111 | 112 | 113 | 114 | 115 | 116 | 117 | 118 | 119 | Designer 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | Global.asax 131 | 132 | 133 | 134 | 135 | 136 | 137 | 138 | 139 | 140 | 141 | 142 | 143 | 144 | 145 | 146 | 147 | 148 | 149 | 150 | 151 | Web.config 152 | 153 | 154 | Web.config 155 | 156 | 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 10.0 166 | $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) 167 | 168 | 169 | 170 | 171 | 172 | 173 | 174 | 175 | True 176 | True 177 | 54490 178 | / 179 | http://localhost:54490/ 180 | False 181 | False 182 | 183 | 184 | False 185 | 186 | 187 | 188 | 189 | 190 | 191 | This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}. 192 | 193 | 194 | 195 | 196 | 203 | -------------------------------------------------------------------------------- /vue-to-mvc5/webpack.config.js: -------------------------------------------------------------------------------- 1 | var path = require('path') 2 | var webpack = require('webpack') 3 | var fs = require('fs') 4 | 5 | var appBasePath = './Scripts/app/' 6 | 7 | var jsEntries = {} 8 | // We search for index.js files inside basePath folder and make those as entries 9 | fs.readdirSync(appBasePath).forEach(function (name) { 10 | var indexFile = appBasePath + name + '/main.js' 11 | if (fs.existsSync(indexFile)) { 12 | jsEntries[name] = indexFile 13 | } 14 | }) 15 | 16 | module.exports = { 17 | entry: jsEntries, 18 | output: { 19 | path: path.resolve(__dirname, './Scripts/bundle/'), 20 | publicPath: '/Scripts/bundle/', 21 | filename: '[name].js' 22 | }, 23 | resolve: { 24 | extensions: ['.js', '.vue', '.json'], 25 | alias: { 26 | 'vue$': 'vue/dist/vue.esm.js', 27 | '@': path.join(__dirname, appBasePath) 28 | } 29 | }, 30 | module: { 31 | loaders: [ 32 | { 33 | test: /\.vue$/, 34 | loader: 'vue-loader', 35 | options: { 36 | loaders: { 37 | scss: 'vue-style-loader!css-loader!sass-loader', //