当您更改字体粗细时,如何阻止文本在悬停时移动?
我的标准<a>有一个font-weight: 300悬停更改font-weight: 700,这会导致文本移动,您如何解决这个问题?
.clearfix:after {
visibility: hidden;
display: block;
font-size: 0;
content: " ";
clear: both;
height: 0;
}
.clearfix {
display: inline-block;
}
/* start commented backslash hack \*/
* html .clearfix {
height: 1%;
}
.clearfix {
display: block;
}
/* close commented backslash hack */
ul {
list-style-type: none;
padding: 0;
margin: 0;
background: #c2c2c2;
font-family: 'Roboto Slab', serif;
}
ul li {
float: left;
display: block;
border-left: 1px …Run Code Online (Sandbox Code Playgroud)我有一个名为"Serverside Project"的文件夹,我想从我的git repo online中删除.我似乎无法摆脱它!我该如何删除它?

我试图使用flexbox将"距离"和"持续时间"文本垂直放置在各自div的中心,我似乎无法让它工作.我也将它应用于"卡路里"和"分享"文本.
我也想使用flexbox在中间列中均匀地间隔我的4x链接.

HTML:
<!DOCTYPE html>
<html>
<head>
<title>Runna - Track your run!</title>
<meta name="viewport" content="width=device-width, initial-scale=1.0 user-scalable=no">
<link rel="stylesheet" type="text/css" href="css/reset.css">
<link rel="stylesheet" type="text/css" href="css/style.css">
<link href='http://fonts.googleapis.com/css?family=Lato:400,700,900' rel='stylesheet' type='text/css'>
<link href="http://maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script src="js/js.js"></script>
</head>
<body>
<div id="main-wrapper">
<div id="head-bar">
<img class="logo" src="imgs/logo-blue.png">
</div>
<div id="map-container">
<iframe src="https://www.google.com/maps/embed?pb=!1m14!1m12!1m3!1d11564.804405086046!2d172.59430635!3d-43.56069255!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!5e0!3m2!1sen!2snz!4v1418977732755" width="100%" height="100%" frameborder="0" style="border:0"></iframe>
</div>
<div id="control-container">
<div class="left-col">
<div class="distance-wrapper">
<div class="distance-title bold-title">DISTANCE:</div>
<div class="distance-figure">1.7KM</div>
</div>
<div class="duration-wrapper">
<div class="duration-title bold-title">DURATION</div>
<div class="duration-figure">10.42MINS</div>
</div>
</div> <!-- End of …Run Code Online (Sandbox Code Playgroud) 如何在悬停时使每个SVG部分变大.我试图复制这个交互式地图的方式:http://goo.gl/orvyYI
我在这里创建了一个基本的交互式地图来测试:
<?xml version="1.0" encoding="utf-8"?>
<!-- Generator: Adobe Illustrator 19.1.0, SVG Export Plug-In . SVG Version: 6.00 Build 0) -->
<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="800px"
height="600px" viewBox="0 0 800 600" style="enable-background:new 0 0 800 600;" xml:space="preserve">
<style type="text/css">
.st0{fill:#C1C1C0;}
.st1{fill:#0FB5CB;}
.st2{fill:#46B649;}
</style>
<g id="Layer_1">
<polygon class="st0" points="76.6,96.1 745.6,96.1 745.6,543.7 188.3,543.7 "/>
</g>
<g id="landmarks-test">
<rect id="1" x="495.2" y="130.6" class="section" width="233.1" height="83.4"/>
<rect id="2" x="495.2" y="235.4" class="section" width="233.1" height="95.9"/>
<rect id="3" x="495.2" y="345.8" class="section" width="233.1" height="84.1"/> …Run Code Online (Sandbox Code Playgroud) 我想要一种拥有“默认登录”的方法,这样当我php artisan migrate:refresh在数据库上执行操作时,我可以在 PLUS 中播种一堆用户,并且每次都有一个具有相同电子邮件和密码的用户帐户。实现这一目标的最佳方法是什么?我认为也许拥有标准用户工厂加上创建默认用户工厂会起作用,但由于它使用相同的用户类,所以它只是创建一个新的标准用户。
用户工厂.php
/** @var \Illuminate\Database\Eloquent\Factory $factory */
use App\User;
use Faker\Generator as Faker;
use Illuminate\Support\Str;
$factory->define(User::class, function (Faker $faker) {
return [
'name' => $faker->name,
'email' => $faker->unique()->safeEmail,
'email_verified_at' => now(),
'password' => '$2y$10$92IXUNpkjO0rOQ5byMi.Ye4oKoEa3Ro9llC/.og/at2.uheWG/igi', // password
'remember_token' => Str::random(10),
];
});
Run Code Online (Sandbox Code Playgroud)
默认用户工厂.php
/** @var \Illuminate\Database\Eloquent\Factory $factory */
use App\User;
use Faker\Generator as Faker;
use Illuminate\Support\Str;
$factory->define(User::class, function (Faker $faker) {
return [
'name' => $faker->name,
'email' => 'test@demo.com',
'email_verified_at' => now(),
'password' => bcrypt('demo123'), …Run Code Online (Sandbox Code Playgroud) 我有一个TestimonalHolder页面类型,其Testimonials页面类型为其子项,每个子项都有一个Message$ db字段来存储证词.
问题是如何$Message在我HomePage.ss的例子中访问该字段,以便我可以遍历它们并将它们放入滑块等.
Testimonials.php
class Testimonials extends Page {
private static $db = array(
'Message' => 'Text'
);
public function getCMSFields() {
$fields = parent::getCMSFields();
$fields->addFieldsToTab('Root.Testimonials', array(
TextareaField::create('Message')
));
return $fields;
}
}
class Testimonials_Controller extends Page_Controller {
}
Run Code Online (Sandbox Code Playgroud)
我知道我可以通过在我的TestimonialHolder.ss页面上使用此代码来遍历它们:
<% loop $Children %>
<h2>$Title</h2>
$Message
<% end_loop %>
Run Code Online (Sandbox Code Playgroud) 你如何使用你@include在sass文件中使用Font awesome图标.
例如 - 如果我想使用此图标:http: //fortawesome.github.io/Font-Awesome/icon/pencil/
我知道您可以在HTML中使用它,如下所示:
<i class="fa fa-pencil"></i>
Run Code Online (Sandbox Code Playgroud)
但是我希望能够做到以下或类似的事情:
.class-name {
@include: fa-icon(fa-pencil);
}
Run Code Online (Sandbox Code Playgroud)
默认/正确的方法是什么?
我希望能够将团队成员与使用该项目的项目相关联ListBoxField.我有一个ProjectHolder具有Project网页,因为它的孩子.我也有一个TeamHolder,其具有TeamPage的作为其子.
我希望能够在其中保存多个团队成员ListBoxField,然后在Project页面上循环访问它们.我还希望能够链接到团队成员页面.例如
<% loop $TeamMemberNames %>
<a href="$Link">$Name</a>
<% end_loop %>
Run Code Online (Sandbox Code Playgroud)
我目前的代码:
TeamPage.php
class TeamPage extends Page
{
private static $db = array(
'Name' => 'Varchar(255)',
);
public function getCMSFields() {
$fields = parent::getCMSFields();
$fields->addFieldToTab('Root.TeamMembers', TextField::create('Name'));
return $fields;
}
}
Run Code Online (Sandbox Code Playgroud)
Project.php
class Project extends Page
{
private static $db = array(
'Name' => 'Varchar(255)',
);
public function getCMSFields() {
$fields = parent::getCMSFields();
$fields->addFieldToTab('Root.TeamMembers', TextField::create('Name'));
$fields->addFieldToTab('Root.TeamMembers', ListBoxField::create( …Run Code Online (Sandbox Code Playgroud) 突然间,当我尝试点击silverstripe后端的页面时,它最初显示如下,我正在运行SS 3.2,当这个开始发生时,我升级到3.2.1,看看是否能解决问题但是没有:
有时它会显示此错误消息以及: [User Warning] Couldn't set response type to 404 because of output on line 1 of /Users/computername/Sites/themename/mysite/code/Pages/HomePage.php
如果我刷新它是正确但然后如果我去添加一些东西gridfield后我点击"创建"它只是去一个空白的屏幕,但它仍然添加到Dataobject.
有什么想法吗?
css ×5
html ×4
silverstripe ×3
bitbucket ×1
css-shapes ×1
css3 ×1
flexbox ×1
font-awesome ×1
fonts ×1
git ×1
laravel ×1
svg ×1