zurb-foundation

Choosing the right front-end framework

时间秒杀一切 提交于 2019-12-06 16:09:56
I'm looking into Bootstrap vs Foundation my criterias are: Lightweight Easily customized Easily build complex HTML layout Mobile / Responsive In my past experience with Bootstrap, building layout from a designer mockup as a "pixel perfect" HTML was not trivial. Your thoughts, ideas are appreciated. Bootstrap and Zurb Foundation are both CSS frameworks, but they have a different purposes. The primary goal of Bootstrap is fast prototyping of websites or web applications that have a base style. Since the styles are opinionated, that makes it more work to get it to match a custom design. It is

Use Foundation instead of Bootstrap with SASS in a yeoman created application

喜夏-厌秋 提交于 2019-12-06 14:17:59
问题 I've created an AngularJS application with yeoman. Now I want to switch the front-end framework from bootstrap to foundation. After I installed foundation with bower install foundation --save Grunt will add the following line to my index.html file. <link rel="stylesheet" href="bower_components/foundation/css/foundation.css" /> How can I force grunt to use the sass way. For the sass way the index.html is untouched (except js files) but the main.scss file nedds the following line or simliar

Zurb Foundation 5: Grid Column Stacking

家住魔仙堡 提交于 2019-12-06 11:49:08
问题 I'm new to foundation and I only have the basic idea on how to use grids. I have these 3 columns that need to be stacked (see "mobile" image) when viewed on mobile/small screens. It should look something like this when in larger screens: Here's my current code. It's not quite what I wanted, and I'm starting to get confused. <div class="row"> <div class="large-12" style="background-color:#bdc3c7;"> <div class="medium-4 medium-push-8 columns" style="background-color: #1abc9c; border: 1px solid

Including static js files in django 1.7

房东的猫 提交于 2019-12-06 11:45:19
Here is part of settings.py : STATIC_URL = '/static/' STATICFILES_DIRS = ( os.path.join(BASE_DIR, 'static'), ) HTML template: {% load staticfiles %} ... <head> <title>HelpDesk System</title> <script scr="{% static "js/vendor/jquery.js" %}" type="text/javascript"></script> <link rel="stylesheet" type="text/css" href="{% static "css/foundation.css" %}"> <script scr="{% static "js/foundation.min.js" %}" type="text/javascript"></script> </head> <body> <script> $(document).ready(function() { $(document).foundation(); }); </script> ... </body> Static folder tree: Result: Css file loads as expected,

How do I integrate Foundation 3 in an AMD manner

孤街醉人 提交于 2019-12-06 09:33:06
EDIT 4 There's a module defined in (from Foundation 3 package) app.js : (function($, window, undefined) { 'use strict'; var $doc = $(document), Modernizr = window.Modernizr; $(document).ready(function() { $.fn.foundationAlerts ? $doc.foundationAlerts() : null; // ... $.fn.foundationClearing ? $doc.foundationClearing() : null; $('input, textarea').placeholder(); }); // touch support detction is omitted })(jQuery, this); I tried to interpret it to the next form: BOOTSTRAP.JS require.config({ paths: { // other paths then.. 'foundation': '../libs/zurb' }, shim: { 'foundation/jquery.foundation

Display error if no checkbox is checked in checkbox group

余生颓废 提交于 2019-12-06 08:02:52
问题 How do I display an error message with Foundation 5's Abide HTML5 form validation library when no checkboxes are checked within the same checkbox group? 回答1: You have to write your own abide validator, but it is quite simple. Working example: CodePen link JavaScript $(document).foundation({ abide: { validators: { checkbox_limit: function(el, required, parent) { var group = parent.closest('.checkbox-group'); var min = group.attr('data-abide-validator-min'); var checked = group.find(':checked')

Justified tabs in Foundation for Apps project

江枫思渺然 提交于 2019-12-06 07:56:12
I'm looking for a way to achieve full-width/justified tabs in a container in my Foundation app. This is what's happening currently. In Twitter Bootstrap I can do this and I'm looking for the same type of functionality in Foundation. Is it possible natively? I'm just using the default tabs structure example right now. Tabs in Foundation use the flexbox model. By default, their flex-grow is 0 (they don't grow to fill up the parent). Change it to 1 and they will. Optionally, you might want to add text-align: center , as now the tab text will be smaller than the tab itself: div.tabs .tab-item {

How do I use Zurb Foundation 4 Sections (tabs) with my javascript Ajax?

倾然丶 夕夏残阳落幕 提交于 2019-12-06 07:26:39
问题 I am using the Zurb Foundation 4.1.5 for my application and I am trying to use Zurb Section Javascript to manage "tabs" on the page. However, the data in the tabs on my page is dynamic and loaded by Ajax calls. I need to know how to render or draw this data on the sections content. My javascript methods a) need to be notified whenever a Tab is selected. b) need to be able to programmatically display or select the active tab c) dynamically set the HTML content for each Tab: I have a moustache

Browserify with Zurb Foundation Framework

两盒软妹~` 提交于 2019-12-06 07:14:07
问题 POST-SOLUTION EDIT Here's a Yeoman generator to scaffold out a project with Foundation and Browserify: https://github.com/dougmacklin/generator-foundation-browserify I'm trying to figure out how to properly bundle the foundation framework js with browserify. In my project folder, I install it along with jQuery (which it depends on): npm install jquery foundation-sites --save Then in my main.js I have the following: var $ = jQuery = require('jquery'); var foundation = require('foundation-sites

Trigger opening of a Zurb Foundation Accordion via URL hash link

大憨熊 提交于 2019-12-06 07:06:43
问题 I'd really like to be able to "activate" / "open" a Zurb Foundation Accordion via the URL with the accordion pane in questions hash. So like example.com/page#accordion1 Is this possible already with Foundation or is it easy to implement? I honestly haven't got a clue :-/ Thanks in advance for any help given! 回答1: You can do this by adding an unique attribute to each accordion title <div class="title" data-ref="panel-1"> In this case I added a data-ref attribute. Then you will need to add some